SA-MP Forums Archive
Pickup Problems - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Pickup Problems (/showthread.php?tid=185072)



Pickup Problems - Infinitas - 23.10.2010

Hola, for a few days now ive been having a few problems with my pickups now showing up. Only 1 out of the 4 will work. Heres the codes:


Код:
pdintpickup = CreatePickup(1318,1,-2161.2522,-2384.8645,30.8946,357.0119,-1); //policeinteriorpickup
	pdextpickup = CreatePickup(1247,1,627.72485352,-571.77148438,18.13291931,-1); //pdexteriorpickup
	cbenter = CreatePickup(1318,1,-2155.2864,-2460.1274,30.8516,-1); 
	cbexit = CreatePickup(1318,1,364.9477,-11.4673,1001.8516,184.7272,-1);
	ammuenter = CreatePickup(1318,-2155.2864,-2460.1274,30.8516,50.2790,-1);
Код:
if(pickupid == pdintpickup)
{
SendClientMessage(playerid,COLOR_WHITE,"You have left the APSD HQ");
SetPlayerPos(playerid,-2163.8142,-2387.3923,30.6250,143.3399);
SetPlayerInterior(playerid,0);
}

if(pickupid == pdextpickup)
{
SendClientMessage(playerid,COLOR_WHITE,"You have entered the APSD HQ");
SetPlayerPos(playerid,246.81053162,64.27899933,1004.08508301);
SetPlayerInterior(playerid,6);
}

if(pickupid == cbenter)
{
SendClientMessage(playerid,COLOR_WHITE,"Welcome to the Cluckin Bell");
SetPlayerPos(playerid,365.7158,-9.8873,1001.8516);
SetPlayerInterior(playerid,9);
}

if(pickupid == cbexit)
{
SendClientMessage(playerid,COLOR_WHITE,"Thanks for coming to the Cluckin Bell!");
SetPlayerPos(playerid,-2153.1350,-2462.2026,30.8438,240.6190);
SetPlayerInterior(playerid,0);
}

if(pickupid == ammuenter)
{
SendClientMessage(playerid,COLOR_WHITE,"You have entered Angel Pine Ammunation.");
SetPlayerPos(playerid,296.919982,-108.071998,1001.515625);
SetPlayerInterior(playerid,6);
}

return 1;
}
I've gone over it for days now and even had other people take a look at it and they couldn't help.
The only pickup that works is the cbenter one.

Help is appreciated,

thanks in advance.


Re: Pickup Problems - Jeffry - 23.10.2010

You can upload the full script at www.pastebin.com and PM me the link, so nobody can steal your script.
I'll try to fix it then.

And, do you have any other scripts, that create any pickups?


Re: Pickup Problems - Infinitas - 23.10.2010

yea... i don't really feel comfortable just giving out my GM...

and no i dont, this is the only one im working with.


Re: Pickup Problems - Badger(new) - 23.10.2010

The parameters for CreatePickup are:
Quote:

(model, type, Float:X, Float:Y, Float:Z, Virtualworld)

pdintpickup = CreatePickup(1318,1,-2161.2522,-2384.8645,30.8946,357.0119,-1); //policeinteriorpickup
pdextpickup = CreatePickup(1247,1,627.72485352,-571.77148438,18.13291931,-1); //pdexteriorpickup
cbenter = CreatePickup(1318,1,-2155.2864,-2460.1274,30.8516,-1);
cbexit = CreatePickup(1318,1,364.9477,-11.4673,1001.8516,184.7272,-1);
ammuenter = CreatePickup(1318,1,-2155.2864,-2460.1274,30.8516,50.2790,-1);

The bold bits at the end are not supposed to be there, the bold & underlined bit on the last one was not there.


Re: Pickup Problems - Infinitas - 23.10.2010

Ah, that little error was the problem. All of them work now, thanks your help Badger!

Yours to Jeffry!