If a player is selling an item? - 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: If a player is selling an item? (
/showthread.php?tid=383255)
If a player is selling an item? -
RLGaming - 06.10.2012
I have an auction system, its nearly done just having trouble with something..
I have these:
Quote:
new ItemSubmitted[MAX_PLAYERS];
new ItemSubmittedName[MAX_PLAYERS][128];
|
CMD:
Quote:
new string[128];
if(dialogid == 3613)
{
if(response)
{
if(listitem == 0)
{
foreach(Player, i)
{
if(ItemSubmitted[i] == 1)
{
// No idea what I can put here to find if people have submitted an item and then submit there name
}
format(string, sizeof(string), "%s is selling %s.", GetPlayerNameEx(i), ItemSubmittedName);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
}
return 1;
}
}
}
|
I cut the other 'listitem' out since they werent needed, I get no errors but I have no idea how I can find players names that have submitted then send it via SCM, I think I did some of it right
Re: If a player is selling an item? -
RLGaming - 06.10.2012
bump
AW: If a player is selling an item? -
Nero_3D - 07.10.2012
pawn Код:
if(ItemSubmitted[i] == 1) // I expect this checks if the player has submitted an item
{ // just moved the code in here
format(string, sizeof(string), "%s is selling %s.", GetPlayerNameEx(i), ItemSubmittedName[i]);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
}