Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Script Help [SOLVED] Rotate entity fixed amount of degrees
Reminiscity Offline
Member

Posts: 81
Threads: 16
Joined: Jan 2013
Reputation: 2
#14
RE: Rotate entity fixed amount of degrees

ResetProp(string& asName); was the key to this work around! This is what I ended up with. This script controls a number of wheels so that's the reason for all the entity + "_wheel" stuff.

void symbolCombination(string &in entity) {

RotatePropToSpeed(entity + "_wheel", 1, 1, 120, 0, 0, true, "");

AddLocalVarInt(entity + "_spins", 1);
AddTimer(entity, 2.59f, "stopWheel");

}

void stopWheel(string &in asTimer)
{

StopPropMovement(asTimer + "_wheel");

if(GetLocalVarInt(asTimer + "_spins") == 3) {

SetLocalVarInt(asTimer + "_spins", 0);
ResetProp(asTimer + "_wheel");
}
}

And it works perfectly Smile Thank you all so much for taking the time to help me I really really appreciated it! Marking this as solved!

My mod Amadeus
03-29-2014, 02:48 PM
Find


Messages In This Thread
RE: Rotate entity fixed amount of degrees - by Reminiscity - 03-29-2014, 02:48 PM



Users browsing this thread: 1 Guest(s)