Meteor 2 Scripting Functions
Projectile
int getProjectileOwner(int projectileID)
Get a projectile owner's object ID.
print(getProjectileOwner(123));
int getProjectileInstigator(int projectileID)
Get a projectile instigators's object ID.
print(getProjectileInstigator(123));
A projectile instigator can differ from the owner. For example if a projectile fired from a vehicle, the vehicle is the owner and the person inside the gunner's seat is the instigator.
float getProjectileSpeed(int projectileID)
Get a projectile's speed.
print(getProjectileSpeed(123));
Speeds are match the projectile editor definition except for fast projectiles (bullets).
vector2 getProjectilePos(int projectileID)
Get a projectile's position in pixels.
print(getProjectilePos(123));
void setProjectilePos(int projectileID, vector2 pos)
Set a projectile's position in pixels (single player/server only).
setProjectilePos(123, getPos(100, 100));
float getProjectileAngle(int projectileID)
Get a projectile's angle in degress.
print(getProjectileAngle(123));
void setProjectileAngle(int projectileID, float angle)
Set a projectile's angle in degress (single player/server only).
setProjectileAngle(123, 180);
Index