03.09.2012, 21:47
Well, Today I made an keypad thing for my LSPD doors and I have a little problem. Always when I am pressing 'enter' anywhere is doing the animation which should do only on the door. How can I fix that ? Codes:
Код:
if(newkeys & KEY_SECONDARY_ATTACK) { if(IsPlayerInRangeOfPoint(playerid, 2.0, 1288.8297,-1019.4271,1085.9760)) if(!IsACop(playerid)) return SendClientMessage(playerid, COLOR_GREY, "You are not an SAPD Officer."); { if(pddoor5opened == false) { ApplyAnimation(playerid, "HEIST9", "Use_SwipeCard", 4.0, 0, 0, 0, 0, 0); MoveDynamicObject(pddoor5, 1289.10, -1018.93, 1085.00, 0.50); pddoor5opened = true; return 1; } else { ApplyAnimation(playerid, "HEIST9", "Use_SwipeCard", 4.0, 0, 0, 0, 0, 0); MoveDynamicObject(pddoor5, 1288.06, -1018.93, 1085.00, 0.50); pddoor5opened = false; return 1; } } } return 1; }