How to save Object Rotation in variable?
#1

Hi, i m trying to make a door and i can make the door open, but i want to get the door closed at the position that the door was.. but i can 't get it work.. anyone know how to do it?

if (IsPlayerNearDynamicObject(playerid, Doors[doorls][0]))
{

SetDynamicObjectRot(Doors[doorls][0], 0, 0, 90);
Doors[doorOpen][0] = true;
SendErrorMessage(playerid, "The door has been opened !");
}


but i want to

GetDynamicObjectRot(Doors[doorls][0]; and save it into variable to use
SetDynamicObjectRot again.. how can i do to close the door?

How can i know the original rotate position of door and show it?

thanks !
Reply
#2

Save the original position/rotation to a variable, set it back to the original pos variable once the user closes the door.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)