Pickup does not appear.
#1

Hey,

Currently I'm working on one of my favorite gamemodes but since around the 2 weeks, some Pickups does not appear in the map anymore.

Here my code:
Код:
stock CreateNewPickup(id, Float:x, Float:y, Float:z)
{
	//Creating pickups.
	new pickup, Text3D:text;
	if(id == 1)
	{
	    pickup = CreatePickup(1239, 1, x, y, z, -1); //1240 -> 1239
	    text = Create3DTextLabel("[REPAIR]", 0x008080FF, x, y, z+0.3,40.0,0);
	    Aantalpickup++;
	    Aantalpickup1[Aantalpickup][pid] = pickup;
	    Aantalpickup1[Aantalpickup][ptext] = text;
	    Aantalpickup1[Aantalpickup][psoort] = 0;
	    Aantalpickup1[Aantalpickup][px] = x;
	    Aantalpickup1[Aantalpickup][py] = y;
	    Aantalpickup1[Aantalpickup][pz] = z;
	    Aantalpickup1[Aantalpickup][pdeleted] = 0;
	}else if(id == 2){
	    pickup = CreatePickup(1239, 1, x, y, z, -1); //1241 -> 1239
	    text = Create3DTextLabel("[NITRO]", 0x008080FF, x, y, z+0.3,40.0,0);
	    Aantalpickup++;
	    Aantalpickup1[Aantalpickup][pid] = pickup;
	    Aantalpickup1[Aantalpickup][ptext] = text;
	    Aantalpickup1[Aantalpickup][psoort] = 1;
 	    Aantalpickup1[Aantalpickup][px] = x;
	    Aantalpickup1[Aantalpickup][py] = y;
	    Aantalpickup1[Aantalpickup][pz] = z;
	    Aantalpickup1[Aantalpickup][pdeleted] = 0;
	}else{
	    pickup = CreatePickup(1239, 1, x, y, z, -1);
	    format(string, sizeof(string), "[%s]", VehicleNames[id-400]);
	    text = Create3DTextLabel(string, 0x008080FF, x, y, z+0.3,40.0,0);
		Carpickup[pickup][pid] = pickup;
		Carpickup[pickup][soort] = id;
		Aantalpickup++;
	    Aantalpickup1[Aantalpickup][pid] = pickup;
	    Aantalpickup1[Aantalpickup][ptext] = text;
	    Aantalpickup1[Aantalpickup][psoort] = 2;
  	    Aantalpickup1[Aantalpickup][px] = x;
	    Aantalpickup1[Aantalpickup][py] = y;
	    Aantalpickup1[Aantalpickup][pz] = z;
	    Aantalpickup1[Aantalpickup][pdeleted] = 0;
	}
	format(string, sizeof(string), "Created pickup ID: %i", pickup);
	print(string);
}
Sorry for the language, but only the last one seems to be working. When you get to the place where the REPAIR or NITRO pickup is, you will only see the TextLabel. So, the coords are right. Somebody know what I'm doing wrong here?

Thanks.
Wouter
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)