Hard Light Productions Forums
Modding, Mission Design, and Coding => FS2 Open Coding - The Source Code Project (SCP) => Topic started by: phreak on December 06, 2002, 06:23:36 pm
-
I'm taking a break from graphics work to work on "Beam helixes". In the few anime shows i've watched, i notices a few types of beams that have spirals around the central beam. I'm trying to recreate such an effect in FS2. Basically, the helix would spriral at three different modes
1 - sine wave (starts at zero, goes to maximum peak at 1/4 the period and minimum peak at 3/4 the period, crosses beams at 0, 1/2, 1)
2 - cosine wave (starts peaked, minimum at 1/2 the period; maximum at 0 and 1, crosses beam at 1/4, 3/4)
3 - spiral (helix stays fixed distance around beam, looks like a spring with a rod through the middle)
-
Cool.:thepimp:
-
hmm... I was thinking about doing something like this,
but you can have it,
the trail code may have some stuff in it of use for getting started
-
something like that with a beam in the middle ?
(i know it isnt a space sim :D )
edit : was a bit big ill do a link
click me :D (http://www.microsoft.com/Games/mw4mercs/img/ss_b_3.jpg)
-
that would be type three
-
that mech beam thing would actualy be rather easy to do
-
the effects i plan on doing won't work with beam tiling and translation.
basically - fire three beams, and have the two outer ones spiral around the middle one
-
ugh that sounds rather complicated
-
Originally posted by PhReAk
the effects i plan on doing won't work with beam tiling and translation.
well that is understandable, odds are you're going to have to break the beam up into a whole buch of segments, and the tileing code would be hard to move into the rendering code for those segments,
though it may be a good idea to use the table entries for them to controle some things like the frequency of the helix and the speed at wich it moves,
the tileing entry has a flag for setting what sort of style you want.
but paresing code is extreemly simple so it doesn't realy mater
-
Quake 2 Rail gun looks something like that
-
Originally posted by Bobboau
that mech beam thing would actualy be rather easy to do
Actually, that's a Gauss Rifle. Nasty weapon, especially mounted in combo with 2 mounted w/ a Thunderbolt.....
-
well i didnt want to go into detail:D (bgetter with 6erlarge btw:D )
but i got a question also
since im a complete , terrible and total newb about this
it also can be mod related idk :)
is it possible to have 3 beams joined up into 1 huge beam ? (like b5 excalibur...) that sounds similar to what your doing phreak
or im totaly wrong and in that case im gona jump out of the window :D
-
No, he wants a beam helix. Ie....a central beam with a rotating beam around the outside that twists and turns through the center one.
-
ye i understood that ;)
just another question from a noob :)
-
Might you be able to something like that with the lightning code(from the nebula), Or you might create a new nebula only weapon with lightning effects.
Just a thought
-
Having tinkered with the beam tiling and translation code a fair bit, I think one and two could easily be done with the code as it is now if the rate at which flickering happens could be set by a table value. Number 3 is a bit tougher if you want the helices to actually respond in 3d to the position of the player like in the pic Fetty posted, since beams right now render in 2D.
But with precise control of the flicker rate, all one would need is an image of a sine wave or cosine wave with which to flicker (since flickering is simply the widening and narrowing of a beam section)
-
Originally posted by PhReAk
I'm taking a break from graphics work to work on "Beam helixes". In the few anime shows i've watched, i notices a few types of beams that have spirals around the central beam. I'm trying to recreate such an effect in FS2. Basically, the helix would spriral at three different modes
Which shows?
and I like the idea!
-
Originally posted by TrashMan
Which shows?
DBZ mostly
-
Vandread uses them as well.....I think.
But if you can do these helixes (as well as keeping the original beams) I can put them to VERY good use! :D
-
most likely i will have a working demo up by friday (hopefully earlier).
nothing special, just beams with lines twirling around them just to demonstrate the idea. I will supply instructions on how to add helixes to a beam.
-
isnt there an easier way to do this? like have the beam map tiled and translate in the direction in which the beam is 'shot'? Then all you have to do to get different effects is change the map; which would look smoother anyways. Some upsides is that it could be useful for other kinds of beam stuff as well ;)
-
That's what I was saying for the sine and cosine waves, Lt. Narol. The helices (no, that's not a typo) can't work the same way, because they have to be 3D to look right.
-
this could be very cool, and the code could be used to improve other things like the damage archs
-
My friend and I worked out some stuff for the z position of the beam:
z = sin(x) + sqrt(-(y * y));
Hope that helps!
-
Originally posted by Analazon
z = sin(x) + sqrt(-(y * y));
I didn't know fs2_open could handle imaginary numbers. :wtf: ;)
-
Originally posted by Analazon
My friend and I worked out some stuff for the z position of the beam:
z = sin(x) + sqrt(-(y * y));
Hope that helps!
Nah! Try using vector graphs.
r(t)=2cos(t)i+2sin(t)j+tk
Vectors rule!
-
Originally posted by Rampage
Nah! Try using vector graphs.
r(t)=2cos(t)i+2sin(t)j+tk
Vectors rule!
meh....I'm not familiar with how DirectX works...and this was a 30 second thing. I think the - needs to be moved outside of the sqrt() in what I wrote...
-
That would make more sense. In your first formula, you were taking the square root of a negative number. :)