29.10.2009, 06:59
Hello all!
Before you scream at me for posting a probably common question, I'd like to say I would have searched prior to posting, but the search feature seems to have been disabled for me. So I suppose me posting this thread is a consequence of being denied access to the search engine. >.< I tried ****** though, but that didn't bring much
Now we got that cleared up, let's get to business
I've been following this tutorial: https://sampwiki.blast.hk/wiki/Fast_Commands
So far every thing works great, except when it comes to sscanf.
When I try compile the code below:
It returns this error:
C:\Documents and Settings\reg\Desktop\samp\filterscripts\cash.pwn(1 73) : error 017: undefined symbol "sscanf"
The only thing I can think of is they forgot to mention an include, or I overlooked it a few times lol
I'm using Pawn compiler 3.2.3664, Windows XP SP2, .Net Framwork 3.5
Before you scream at me for posting a probably common question, I'd like to say I would have searched prior to posting, but the search feature seems to have been disabled for me. So I suppose me posting this thread is a consequence of being denied access to the search engine. >.< I tried ****** though, but that didn't bring much

Now we got that cleared up, let's get to business

I've been following this tutorial: https://sampwiki.blast.hk/wiki/Fast_Commands
So far every thing works great, except when it comes to sscanf.
When I try compile the code below:
Код:
public OnPlayerCommandText(playerid, cmdtext[]) { dcmd(givecash, 8, cmdtext); return 0; } dcmd_givecash(playerid, params[]) { new giveplayerid, amount; if (sscanf(params, "ud", giveplayerid, amount)) SendClientMessage(playerid, 0xFF0000AA, "Usage: /givecash [playerid/partname] [amount]"); else if (giveplayerid == INVALID_PLAYER_ID) SendClientMessage(playerid, 0xFF0000AA, "Player not found"); else if (amount > GetPlayerMoney(playerid)) SendClientMessage(playerid, 0xFF0000AA, "Insufficient Funds"); else { GivePlayerMoney(giveplayerid, amount); GivePlayerMoney(playerid, 0 - amount); SendClientMessage(playerid, 0x00FF00AA, "Money sent"); SendClientMessage(giveplayerid, 0x00FF00AA, "Money received"); } return 1; }
C:\Documents and Settings\reg\Desktop\samp\filterscripts\cash.pwn(1 73) : error 017: undefined symbol "sscanf"
The only thing I can think of is they forgot to mention an include, or I overlooked it a few times lol
I'm using Pawn compiler 3.2.3664, Windows XP SP2, .Net Framwork 3.5