![]() |
#1 |
Little Clucker
![]() Join Date: Apr 2016
Posts: 18
Reputation: 0
|
![]()
Hi, I have not a big problem, but I do not know how to solve.
Loot system with include j_inventory How to run my system: I pick up the loot, for example I don't need it and I throw it. Select the second, third and so on... The problem is that when I want to select only 1 loot, then getting thrown out. I have a total new Float: x_loot, Float: y_loot, Float: z_loot. I use it in check when picked up loot on the button and still use when get the coordinates of the person and under it create the object (removing from inventory). I hope you understand me example: (when you dispose of the loot) Code:
if(dialogid == 8000) { if(response) { if(listitem == 0) { new Float:health; GetPlayerHealth(playerid,health),ClearAnimLoop(playerid),LoopingAnim(playerid,"FOOD","EAT_Burger", 4.1, 0, 1, 1, 1, 1);//êóøàòü if(health<80) SetPlayerHealth(playerid, health+20); SendClientMessage(playerid, COLOR_WHITE, "Âû ñúåëè áîáû"); } if(listitem == 1) { if(!strcmp(itemname,"Áàíêà áîáîâ",true)) { RemoveItem(playerid,itemname,1); GetPlayerPos(playerid, x_loot,y_loot,z_loot); LootObjects[0] = CreateObject(1666,x_loot,y_loot,z_loot-1,0,0,0); SendClientMessage(playerid, COLOR_WHITE, "Âû âûêèíóëè áàíêó áîáîâ!"); } } } } |
![]() |
![]() |
![]() |
#2 |
Big Clucker
![]() ![]() Join Date: Jul 2017
Posts: 91
Reputation: 5
|
![]()
I suggest you make the loot system using OnPlayerKeyStatChange to detect if the person pressed a button or not, If yes, Detect which weapon he is holding, And then create a pickup with the same weapon he held
Then just get rid of the weapon he was holding, It's a lot of code, but it turns out really good |
![]() |
![]() |
![]() |
#3 |
Little Clucker
![]() Join Date: Apr 2016
Posts: 18
Reputation: 0
|
![]()
thanks, but I have another option. And I hope it will work
|
![]() |
![]() |
![]() |
#4 |
Big Clucker
![]() ![]() Join Date: Jul 2017
Posts: 91
Reputation: 5
|
![]() |
![]() |
![]() |
![]() |
Thread Tools | |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Float:Angle2D(Float:PointA[], Float:PointB[]) warning but I don't get it why... | Scrillex | Scripting Help | 6 | 26/03/2013 12:52 AM |
Whats the easy way to get (Float:minx, Float:miny, Float:maxx, Float:maxy) for GangZoneCreate | Issam | Scripting Help | 8 | 18/09/2011 06:16 PM |
Move3DTextLabel(ID, string[], color, Float:NewX, Float:NewY, Float:NewZ) | Eazy_Efolife | Help Archive | 5 | 28/06/2011 10:17 PM |
OnPlayerClick(playerid, Float:x, Float:y, Float:z) [HELP] | Medal Of Honor team | Help Archive | 7 | 28/03/2011 01:57 PM |
GetArea(&Float:minx,&Float:miny,&Float:maxx,&Float:maxy) | pagie1111 | Help Archive | 2 | 14/04/2010 10:39 AM |