Simple gravity script with Multiplier

This is a simple script that I find rather useful! Especially when having larger enemies or other weighted objects.
How it works:
Basically you put the command setGrav(1) where 1 is the multiplier. You can make something light as a feather and make it fall super slow or heavy as can be and make it fall super fast. you also may be able to reverse gravity this way. Haven't tried it.
Heres the script:
This needs to be put in Global Code somewhere.
Enjoy
How it works:
Basically you put the command setGrav(1) where 1 is the multiplier. You can make something light as a feather and make it fall super slow or heavy as can be and make it fall super fast. you also may be able to reverse gravity this way. Haven't tried it.
Heres the script:
- Code: Select all
double gravity=.5;
void setGrav(double multiplier)
{
yvelocity+=gravity*multiplier;
}
This needs to be put in Global Code somewhere.
Enjoy