10.07.2009, 18:27
What's the problem?
I am a beginner in this field, and an inability to cope with the script to pickup!
What's the idea?
When I have driven me to this pickup Teleport to the site with all vehcile!
Screens!
[img width=1024 height=640]http://i27.tinypic.com/mjodc4.jpg[/img]
[img width=1024 height=640]http://i31.tinypic.com/epekp4.jpg[/img]
My script!
Sorry about spelling mistakes!
I am a beginner in this field, and an inability to cope with the script to pickup!
What's the idea?
When I have driven me to this pickup Teleport to the site with all vehcile!
Screens!
[img width=1024 height=640]http://i27.tinypic.com/mjodc4.jpg[/img]
[img width=1024 height=640]http://i31.tinypic.com/epekp4.jpg[/img]
My script!
Quote:
public OnPlayerPickUpPickup(playerid, pickupid) { new pName[MAX_PLAYER_NAME]; new string[256]; GetPlayerName(playerid, pName, sizeof(pName)); format(string, sizeof(string), "%s izpildija (Secret-Stunt)!", pName); SendClientMessageToAll(0xAAAAAAAA, string); SetPlayerPos(playerid,2299.0811,-1810.9479,13.1600); PlayerPlaySound(playerid, 1057, 2299.0811,-1810.9479,13.1600); GivePlayerMoney(playerid, 5000); SendClientMessage(playerid,0x8000FFFF,"Tu atklaji 'Secret-Spot' un ieguvi 5000$!"); if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER) { SetVehiclePos(GetPlayerVehicleID(playerid), 0, 0, 0); SetVehicleZAngle(GetPlayerVehicleID(playerid), 0); } else { SetPlayerPos(playerid, 0, 0, 0); SetPlayerFacingAngle(playerid, 0); } return true; } public OnPlayerUpdate(playerid) { if(IsPlayerConnected(playerid)) { new Float:TmpPos[3]; GetPlayerPos(playerid, TmpPos[0], TmpPos[1], TmpPos[2]); TmpPos[0] -= (2477.4807,-1689.7860,27.1281); TmpPos[1] -= (1918.2307,-1797.1493,27.9182); TmpPos[2] -= (2753.5242,-1641.5155,32.119; if( ((TmpPos[0] * TmpPos[0]) + (TmpPos[1] * TmpPos[1]) + (TmpPos[2] * TmpPos[2])) < 4) { new pName[MAX_PLAYER_NAME]; new string[256]; GetPlayerName(playerid, pName, sizeof(pName)); format(string, sizeof(string), "%s izpildija (Secret-Stunt)!", pName); SendClientMessageToAll(0xAAAAAAAA, string); SetPlayerPos(playerid,2277.5903,-2180.5654,5.6720); PlayerPlaySound(playerid, 1057, 2277.5903,-2180.5654,5.6720); GivePlayerMoney(playerid, 5000); SendClientMessage(playerid,0x8000FFFF,"Tu atklaji 'Secret-Spot' un ieguvi 5000$!"); if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER) { SetVehiclePos(GetPlayerVehicleID(playerid), 0, 0, 0); SetVehicleZAngle(GetPlayerVehicleID(playerid), 0); } else { SetPlayerPos(playerid, 0, 0, 0); SetPlayerFacingAngle(playerid, 0); } } } return true; } |