CreateDynamicPickup - 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)
+--- Thread: CreateDynamicPickup (
/showthread.php?tid=392968)
CreateDynamicPickup -
Konstantinos - 16.11.2012
Hello, I'm making a house system and I decided to use Incognito's Streamer for Dynamic pickups. For an unknown reason, it doesn't work. I have test it with CreatePickup and it works fine but I would like to know why it doesn't work.
pawn Код:
House[ x ][ HOUSE_PICKUP ] = CreateDynamicPickup( 1272, 1, House[ x ][ HOUSE_X ], House[ x ][ HOUSE_Y ], House[ x ][ HOUSE_Z ], 0, 0, -1, 100.0 );
//House[ x ][ HOUSE_PICKUP ] = CreatePickup( 1272, 1, House[ x ][ HOUSE_X ], House[ x ][ HOUSE_Y ], House[ x ][ HOUSE_Z ], 0 );
pawn Код:
public OnPlayerPickUpPickup( playerid, pickupid )
{
for( new x; x < rows; x++ )
{
if( House[ x ][ HOUSE_PICKUP ] == pickupid )
{
format( Query, sizeof( Query ), "House Name: %s", House[ x ][ HOUSE_NAME ] );
SendClientMessage( playerid, -1, Query );
}
}
return 1;
}
The message is displayed only by creating a normal pickup, not dynamic.
Re: CreateDynamicPickup -
ViniBorn - 16.11.2012
Use this
pawn Код:
public OnPlayerPickUpDynamicPickup(playerid, pickupid);
Re: CreateDynamicPickup -
kanersps - 16.11.2012
Quote:
Originally Posted by Viniborn
Use this
pawn Код:
public OnPlayerPickUpDynamicPickup(playerid, pickupid);
|
This worked by me
Re: CreateDynamicPickup -
Konstantinos - 16.11.2012
Quote:
Originally Posted by Viniborn
Use this
pawn Код:
public OnPlayerPickUpDynamicPickup(playerid, pickupid);
|
Oh, how silly I am!

That worked, thanks a lot.