Skip navigation

About the dafault values used

Forum NavigationHome > Forum Index > Tread Marks > About the dafault values used
Pages 1 2
Level 12 Human gamer
Alignment: Good
Posted on January 3, 2008 at 8:49 pm

I think that here there are many persons who no longer play online TM :roll: sorry

Level 14 Human Sr Code Monkey
Alignment: Chaotic
Location: lost in the evil lands, of soccer-mom piloted minivans....
Posted on January 4, 2008 at 12:44 am

I figured I should give an example of how to build spewers to fire in fixed directions.

Say we want to fire 5 projectiles in a circle. With 5 projectiles that means:

360 degrees in a circle / 5 projectiles = 72 degrees between each projectile.

so we want to fire projectiles at the following angles:
0, 72, 144, 216, 288

we pick a horizontal velocity of 100 m/s and we run through the calculations. Since I want the projectiles to spew from a central point and fly up and out, I need to solve for the x (east/west) and z (north/south) coordinates. The y (up/down) coordinate will be fixed at 100 m/s for all spewers.

[code:1:78a228c363]min/max Z = cos(a) * velocity = cos(0) * 100 = 100
min/max X = sin(a) * velocity = sin(0) * 100 = 0
[/code:1:78a228c363]
[code:1:78a228c363]min/max Z = cos(a) * velocity = cos(72) * 100 = 30.9016
min/max X = sin(a) * velocity = sin(72) * 100 = 95.0156
[/code:1:78a228c363]
[code:1:78a228c363]min/max Z = cos(a) * velocity = cos(144) * 100 = -80.9016
min/max X = sin(a) * velocity = sin(144) * 100 = 58.7785
[/code:1:78a228c363]
[code:1:78a228c363]min/max Z = cos(a) * velocity = cos(216) * 100 = -80.9016
min/max X = sin(a) * velocity = sin(216) * 100 = -58.7785
[/code:1:78a228c363]
[code:1:78a228c363]min/max Z = cos(a) * velocity = cos(288) * 100 = 30.9016
min/max X = sin(a) * velocity = sin(288) * 100 = -95.0156
[/code:1:78a228c363]

Now that we have our values we create 5 spewers which we can either chain using entitychain, or spew using another spewer. Assuming a verticle velocity of 100 m/s, these 5 spewers will have the following settings:

[code:1:78a228c363]SpewMin = 0, 100, 100
SpewMax = 0, 100, 100
[/code:1:78a228c363]
[code:1:78a228c363]SpewMin = 95.0156, 100, 30.9016
SpewMax = 95.0156, 100, 30.9016
[/code:1:78a228c363]
[code:1:78a228c363]SpewMin = 58.7785, 100, -80.9016
SpewMax = 58.7785, 100, -80.9016
[/code:1:78a228c363]
[code:1:78a228c363]SpewMin = -58.7785, 100, -80.9016
SpewMax = -58.7785, 100, -80.9016
[/code:1:78a228c363]
[code:1:78a228c363]SpewMin = -95.0156, 100, 30.9016
SpewMax = -95.0156, 100, 30.9016
[/code:1:78a228c363]

and thats about it. This will give you 5 ents being spewed in a circle.

Level 12 Human gamer
Alignment: Good
Posted on January 4, 2008 at 11:20 am

I figured I should give an example of how to build spewers to fire in fixed directions.

Say we want to fire 5 projectiles in a circle. With 5 projectiles that means:

360 degrees in a circle / 5 projectiles = 72 degrees between each projectile.

so we want to fire projectiles at the following angles:
0, 72, 144, 216, 288

we pick a horizontal velocity of 100 m/s and we run through the calculations. Since I want the projectiles to spew from a central point and fly up and out, I need to solve for the x (east/west) and z (north/south) coordinates. The y (up/down) coordinate will be fixed at 100 m/s for all spewers.

[code:1:af0a90f75c]min/max Z = cos(a) * velocity = cos(0) * 100 = 100
min/max X = sin(a) * velocity = sin(0) * 100 = 0
[/code:1:af0a90f75c]
[code:1:af0a90f75c]min/max Z = cos(a) * velocity = cos(72) * 100 = 30.9016
min/max X = sin(a) * velocity = sin(72) * 100 = 95.0156
[/code:1:af0a90f75c]
[code:1:af0a90f75c]min/max Z = cos(a) * velocity = cos(144) * 100 = -80.9016
min/max X = sin(a) * velocity = sin(144) * 100 = 58.7785
[/code:1:af0a90f75c]
[code:1:af0a90f75c]min/max Z = cos(a) * velocity = cos(216) * 100 = -80.9016
min/max X = sin(a) * velocity = sin(216) * 100 = -58.7785
[/code:1:af0a90f75c]
[code:1:af0a90f75c]min/max Z = cos(a) * velocity = cos(288) * 100 = 30.9016
min/max X = sin(a) * velocity = sin(288) * 100 = -95.0156
[/code:1:af0a90f75c]

Now that we have our values we create 5 spewers which we can either chain using entitychain, or spew using another spewer. Assuming a verticle velocity of 100 m/s, these 5 spewers will have the following settings:

[code:1:af0a90f75c]SpewMin = 0, 100, 100
SpewMax = 0, 100, 100
[/code:1:af0a90f75c]
[code:1:af0a90f75c]SpewMin = 95.0156, 100, 30.9016
SpewMax = 95.0156, 100, 30.9016
[/code:1:af0a90f75c]
[code:1:af0a90f75c]SpewMin = 58.7785, 100, -80.9016
SpewMax = 58.7785, 100, -80.9016
[/code:1:af0a90f75c]
[code:1:af0a90f75c]SpewMin = -58.7785, 100, -80.9016
SpewMax = -58.7785, 100, -80.9016
[/code:1:af0a90f75c]
[code:1:af0a90f75c]SpewMin = -95.0156, 100, 30.9016
SpewMax = -95.0156, 100, 30.9016
[/code:1:af0a90f75c]

and thats about it. This will give you 5 ents being spewed in a circle.



That may work :roll:

Pages 1 2