parallel animation with different (random) start-frame
-
- Elite
- Posts: 1454
- Joined: Sun Jan 12, 2003 6:24 pm
- Location: Far out in the uncharted backwaters of the unfashionable end of the western spiral arm of the Galaxy
- Contact:
parallel animation with different (random) start-frame
I haven't found a way to define a random start frame for animations.
So the same animation used several times in the same unit/whatever will NOT be synchron.
Is this (easy) possible with the VS-engine?
practical example:
* photon torpedo
* several (~4) animated "sparks" (getting bigger and smaller)
* unfortunately the animations all start at the same time/frame
Is there more use for this feature?
Pontiac
So the same animation used several times in the same unit/whatever will NOT be synchron.
Is this (easy) possible with the VS-engine?
practical example:
* photon torpedo
* several (~4) animated "sparks" (getting bigger and smaller)
* unfortunately the animations all start at the same time/frame
Is there more use for this feature?
Pontiac
-
- Developer
- Posts: 3980
- Joined: Fri Jan 03, 2003 4:53 am
- Location: Stanford, CA
- Contact:
I could prolly make it start at a random frame if you specify a tag...
why not, eh?
usually starting at frame 0 is a big advantage
why not, eh?
usually starting at frame 0 is a big advantage
Vega Strike Lead Developer
http://vegastrike.sourceforge.net/
http://vegastrike.sourceforge.net/
-
- Elite
- Posts: 1454
- Joined: Sun Jan 12, 2003 6:24 pm
- Location: Far out in the uncharted backwaters of the unfashionable end of the western spiral arm of the Galaxy
- Contact:
So something like this will be possible (The animation starts at the beginning without the 'random' tag.)?hellcatv wrote:I could prolly make it start at a random frame if you specify a tag...
why not, eh?
Code: Select all
10 10
20 0.1 random
textureframe1.xxx alphaframe1.png
textureframe2.png alphaframe2.png
.. ..
But not always intended. Just think of animations which are scaled bigger and smaller all the time. (see photon example)usually starting at frame 0 is a big advantage
So when i put some of them in the same place they will animate synchon......looking very odd
Pontiac
-
- Developer
- Posts: 3980
- Joined: Fri Jan 03, 2003 4:53 am
- Location: Stanford, CA
- Contact:
well now you can specify a startframe in the mesh tag
and if you make it RANDOM then it'll choose a random one
if you make it ASYNC then each mesh will start on a random frame instead of the whole unit starting together
sound good?
I'll commit a binary soon
and if you make it RANDOM then it'll choose a random one
if you make it ASYNC then each mesh will start on a random frame instead of the whole unit starting together
sound good?
I'll commit a binary soon
Vega Strike Lead Developer
http://vegastrike.sourceforge.net/
http://vegastrike.sourceforge.net/
-
- Elite
- Posts: 1454
- Joined: Sun Jan 12, 2003 6:24 pm
- Location: Far out in the uncharted backwaters of the unfashionable end of the western spiral arm of the Galaxy
- Contact:
Whoot, that was a fast coding-responsehellcatv wrote:well now you can specify a startframe in the mesh tag
and if you make it RANDOM then it'll choose a random one
if you make it ASYNC then each mesh will start on a random frame instead of the whole unit starting together
sound good?
I'll commit a binary soon
Just to make things clear (at least for me)... are we talking mesh- or picture-animation now?
$me meant picture-animations in the first post (-> the scaling effect of the sparks is created by a picture animation).
Pontiac
-
- Developer
- Posts: 3980
- Joined: Fri Jan 03, 2003 4:53 am
- Location: Stanford, CA
- Contact:
oh--I thought you meant mesh animations.... hmm picture animations... I'll have to think about that....
Vega Strike Lead Developer
http://vegastrike.sourceforge.net/
http://vegastrike.sourceforge.net/
-
- Elite
- Posts: 1454
- Joined: Sun Jan 12, 2003 6:24 pm
- Location: Far out in the uncharted backwaters of the unfashionable end of the western spiral arm of the Galaxy
- Contact:
My bad, should have written more clearly what i meant.hellcatv wrote:oh--I thought you meant mesh animations....
Thanks anyway for the mesh-animation features, I think they will be as usefull as the one for picture animations.
If they all point to one animation/picture I think it would be a pain to code thishmm picture animations... I'll have to think about that....
Pontiac
-
- Developer
- Posts: 3980
- Joined: Fri Jan 03, 2003 4:53 am
- Location: Stanford, CA
- Contact:
any given mesh must have the same texture active at a given time ....
but if you want to make that mesh start at a random frame then you can do
<Meshfile texturestarttime="RANDOM" file="nova.xmesh"/>
or specify a concrete time...
but if you have 2 novas or 2 photons then you're outta luck--unless you make 2 similar meshes with the photon animation--the reason is that we need all the meshes to have the same texture so that drawing speed may be improved to the maximum (save memory bandwidth)
if you want animated meshes to start at a random frame this is how:
<Meshfile startframe="RANDOM" file="nova.xmesh"/>
hope that helps...it's not perfect but it'll have to do...
if you want you can make the geometry animate...2 frames of that...then each one can have its texture in a different place
or something....
but if you want to make that mesh start at a random frame then you can do
<Meshfile texturestarttime="RANDOM" file="nova.xmesh"/>
or specify a concrete time...
but if you have 2 novas or 2 photons then you're outta luck--unless you make 2 similar meshes with the photon animation--the reason is that we need all the meshes to have the same texture so that drawing speed may be improved to the maximum (save memory bandwidth)
if you want animated meshes to start at a random frame this is how:
<Meshfile startframe="RANDOM" file="nova.xmesh"/>
hope that helps...it's not perfect but it'll have to do...
if you want you can make the geometry animate...2 frames of that...then each one can have its texture in a different place
or something....
Vega Strike Lead Developer
http://vegastrike.sourceforge.net/
http://vegastrike.sourceforge.net/
-
- Elite
- Posts: 1465
- Joined: Thu Jan 02, 2003 12:01 pm
- Location: Seattle, WA
- Contact:
-
- Elite
- Posts: 1454
- Joined: Sun Jan 12, 2003 6:24 pm
- Location: Far out in the uncharted backwaters of the unfashionable end of the western spiral arm of the Galaxy
- Contact:
Not sure, but unfortunately I can't use this method for the existing photon torpedo (i think).PeteyG wrote:I think it would be fine that way, Dan. It looks fine when all parts of a single torpedo are in sync... but having each individual torpedo in a spread look a bit different would definately be a good thing.
It'll work that way, right?
The reason is: I used the accessory-method (no mesh-frames needed) instead of the mesh-animation method.
And to simulate the growing/pulsing of the "spikes" I just used an animated texture.
When using the accessory-method the only thing in synch is the texture-animation of the torpedos.
The rotating part is started exactly when the torpedo is launched (shifted in time).
But i may be wrong .... it's a bit late (after midnight here)...had a long day ..... must go to beeeeee....*yawn*...eeed.
@hellcatv:
Updated the wiki entry about editing unit files (VsHowtoEditUnitFiles).
I hope I got it right.
Pontiac