Page 1 of 1
I need help with stuff, mostly animation
Posted: 11 Jun 2007, 21:36
by rcdraco
Ok, for starters, I want to know how to make it so that a unit spins it's top when it is on, but not off,[Possibly a metal extractor pacing script] and make a bubbly effect from my units feet as it moves, to simulate hovering.
Posted: 11 Jun 2007, 23:37
by rattle
Code: Select all
static-var bubblyFeet;
#define FX_BUBBLES 1024
#define SFX_SLEEP_TIME 250
...
SFXLoop()
{
while (TRUE)
{
if (bubblyFeet)
{
emit-sfx FX_BUBBLES from feet;
}
sleep SFX_SLEEP_TIME;
}
}
Activate()
{
start-spin spinning_thing around y-axis speed <45> accelerate <5>;
bubblyFeet = TRUE;
}
Deactivate()
{
stop-spin spinning_thing around y-axis decelerate <15>;
bubblyFeet = FALSE;
}
Create()
{
start-script SFXLoop();
// assuming this building is activated by default
bubblyFeet=TRUE;
start-spin spinning_thing around y-axis speed <45>;
}
Put an explosion generator effect on the unit which looks like some bubbles and you're set to go.
Posted: 11 Jun 2007, 23:44
by Zoy64
the code confuses me

sorry
Posted: 12 Jun 2007, 00:16
by rcdraco
I meant 2 different scripts, one where the unit's top spins, and another for hovercrafts where the bubbles come out of the feet.
This is the hovercraft, notice the "feet".
And for a spinner, it is one for my metal extractor, and another for my radar unit.
Strangely enough the script there looks lie a script for a hovercraft radar unit.
Posted: 12 Jun 2007, 15:29
by rattle
Ok, for starters, I want to know how to make it so that a unit spins it's top when it is on, but not off,[Possibly a metal extractor pacing script] and make a bubbly effect from my units feet as it moves*, to simulate hovering.
*moves as in spins
That's what I understood.
Anyway, you should start by decobbling some of TA's COBs
(especially hovercrafts or ships) and read through maestro's guide. Or look at other mods which include their scripts as BOS.
You can ignore the post above, I get what you mean with bubbles now.
"emit-sfx 256|3 from piece;" = sea state/bubbles. Piece should be an object with two vertices preferably, although upspring might make a fuss about it.
Posted: 12 Jun 2007, 17:20
by FLOZi
or, you know, emit-sfx 259.
Posted: 12 Jun 2007, 19:17
by Peet
rattle wrote:Piece should be an object with two vertices preferably, although upspring might make a fuss about it.
It does.
Empty objects work fine for me.
umm
Posted: 18 Jun 2007, 17:51
by rcdraco
I can't seem to figure out how to make a simple script like this, Scriptor doesn't like the script, and won't make a cob. And I don't have the header files anywhere.
Posted: 18 Jun 2007, 19:11
by rattle
P3374H wrote:rattle wrote:Piece should be an object with two vertices preferably, although upspring might make a fuss about it.
It does.
Empty objects work fine for me.
Alright, haven't touched ships yet. All I know is that wake pieces in OTA models have two vertices but good to hear.
rcdraco wrote:I can't seem to figure out how to make a simple script like this, Scriptor doesn't like the script, and won't make a cob. And I don't have the header files anywhere.
The header files are where you installed scriptor to.
myself wrote:Anyway, you should start by decobbling some of TA's COBs (especially hovercrafts or ships) and read through maestro's guide. Or look at other mods which include their scripts as BOS.