Advertisement
Guest User

heatON

a guest
Jan 2nd, 2009
397
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.03 KB | None | 0 0
  1. if (strcmp(cmd, "/r", true) == 0)
  2. {
  3. if (IsLogged[playerid])
  4. {
  5. if (SavedPosition[playerid] == 1)
  6. {
  7. if (!IsPlayerInAnyVehicle(playerid))
  8. {
  9. SetPlayerPos(playerid,PlayerPosition[playerid][0],PlayerPosition[playerid][1],PlayerPosition[playerid][2]);
  10. SetPlayerFacingAngle(playerid,PlayerPosition[playerid][3]);
  11. SendClientMessage(playerid,GREEN,"Teleported to the last saved position!");
  12. }
  13. else
  14. {
  15. SetVehiclePos(GetPlayerVehicleID(playerid),PlayerPosition[playerid][0],PlayerPosition[playerid][1],PlayerPosition[playerid][2]);
  16. SetVehicleZAngle(GetPlayerVehicleID(playerid),PlayerPosition[playerid][3]);
  17. SendClientMessage(playerid,GREEN,"Teleported to the last saved position!");
  18. }
  19. }
  20. else SendClientMessage(playerid,RED,"You didn't save a position! ( /s )");
  21. }
  22. else SendClientMessage(playerid,RED,"You have to be logged in to use this command! ( /login )");
  23. return 1;
  24. }
  25.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement