Jump to content
View in the app

A better way to browse. Learn more.

GTAGames.nl - De Nederlandse Grand Theft Auto Community!

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

invalid delclaration en never used symbol

ik was bezig met script maar als ik denk dat ik goed heb zegt ie bijv array indexed (variable cmd1

en invalid function bij tmp1 en cmd1 en idx en never used symbol money ect

kan iemand me helpen met oplossen? volgens het cashsysteem van sandra ^^

bedankt alvast :tu:

new cmd1[256],tmp1[256], idx1;

if(strcmp(cmd, "/givemoney", true)==0)

{

new moneyplayer, money;

tmp1 = strtok(cmdtext,idx1);

if(!strlen(tmp1))

{

SendClientMessage(playerid, 0xFF0000AA, "Use: /giveplayermoney [playerid] [amount]");

return 1;

}

moneyplayer = strval(tmp1);

tmp1 = strtok(cmdtext,idx1);

if(!strlen(tmp1))

{

SendClientMessage(playerid, 0xFF0000AA, "Use: /giveplayermoney [playerid] [amount]");

return 1;

}

money = strval(tmp1);

GivePlayerMoney(playerid, -money);

GivePlayerMoney(moneyPlayer, money);

return 1;

}

Edited by tinyq

Featured Replies

if(strcmp(cmd, "/givemoney", true)==0)
{
new moneyplayer, money;
tmp = strtok(cmdtext,idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, 0xFF0000AA, "Use: /giveplayermoney [playerid] [amount]");
return 1;
}
moneyplayer = strval(tmp);
tmp1 = strtok(cmdtext,idx); 
if(!strlen(tmp))
{
SendClientMessage(playerid, 0xFF0000AA, "Use: /giveplayermoney [playerid] [amount]");
return 1;
}
money = strval(tmp);
GivePlayerMoney(playerid, -money);
GivePlayerMoney(moneyplayer, money);
return 1;
}

Ik weet niet zeker waarom je cmd1 tmp1 en idx1 gebruikt...

Anyway ik weet niet zeker of je arrays zo kan definen(achter elkaar)

dus niet zo:

new array1[256],array2[256];

maar zo:

new array1[256];

new array2[256];

Maarja als je GivePlayerMoney gebruikt zou je op zijn minst IsPlayerConnect(moneyplayer) doen want als het een valse id is dan crasht je server.

Edited by danik

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

Recently Browsing 0

  • No registered users viewing this page.

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.