SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Reply
 
Thread Tools Display Modes
Old 10/06/2013, 01:07 PM   #1
xFirex
Big Clucker
 
Join Date: May 2013
Posts: 94
Reputation: 17
Default warning 215: expression has no effect

hmm here the code

pawn Code:
CMD:needrank(playerid,params[])
{
#pragma unused params
GivePlayerRankScore(playerid,20);//after i remove this, i didn't get any error
return 1;
}

stock GivePlayerRankScore(playerid,amount)
{
PlayerInfo[playerid][pRankScore] +amount;//error line
}

gelp pls
xFirex is offline   Reply With Quote
Old 10/06/2013, 01:09 PM   #2
dannyk0ed
Gangsta
 
dannyk0ed's Avatar
 
Join Date: Mar 2011
Posts: 783
Reputation: 39
Default Re: warning 215: expression has no effect

pawn Code:
[PlayerInfo[playerid][pRankScore] = amount;

Try that.
__________________
-Ex - HBG/InterGaming Developer (2 years)
dannyk0ed is offline   Reply With Quote
Old 10/06/2013, 01:09 PM   #3
HurtLocker
Gangsta
 
HurtLocker's Avatar
 
Join Date: Dec 2012
Location: Hellas, Thessaloniki
Posts: 569
Reputation: 29
Default AW: warning 215: expression has no effect

PlayerInfo[playerid][pRankScore] = PlayerInfo[playerid][pRankScore]+amount;
__________________
Join Fallout's Best TDM server ever!
Useful command: Sounds finder
Turotial: Making a textdraw without editors
HurtLocker is offline   Reply With Quote
Old 10/06/2013, 01:11 PM   #4
xFirex
Big Clucker
 
Join Date: May 2013
Posts: 94
Reputation: 17
Default Re: warning 215: expression has no effect

with one ?
xFirex is offline   Reply With Quote
Old 10/06/2013, 01:11 PM   #5
jakejohnsonusa
Gangsta
 
jakejohnsonusa's Avatar
 
Join Date: Jun 2012
Location: USA
Posts: 854
Reputation: 28
Default Re: warning 215: expression has no effect

Try adding the stock above the CMD (if it's like that in your gamemode), also what is the #pragma unused params for?
jakejohnsonusa is offline   Reply With Quote
Old 10/06/2013, 01:11 PM   #6
Parka
High-roller
 
Parka's Avatar
 
Join Date: Aug 2011
Location: Venezuela
Posts: 1,666
Reputation: 318
Default Respuesta: warning 215: expression has no effect

pawn Code:
stock GivePlayerRankScore(playerid,amount)
{
    PlayerInfo[playerid][pRankScore] += amount;
}
Parka is offline   Reply With Quote
Old 10/06/2013, 01:13 PM   #7
xFirex
Big Clucker
 
Join Date: May 2013
Posts: 94
Reputation: 17
Default Re: warning 215: expression has no effect

Quote:
Originally Posted by dannyk0ed View Post
pawn Code:
[PlayerInfo[playerid][pRankScore] = amount;

Try that.

this is SetPlayerRankScore not GivePlayerRankScore anyway tnx to HurtLocker
xFirex is offline   Reply With Quote
Old 10/06/2013, 01:16 PM   #8
xFirex
Big Clucker
 
Join Date: May 2013
Posts: 94
Reputation: 17
Default Re: warning 215: expression has no effect

help, why i used

stock GivePlayerRankScore(playerid,amount)
{
PlayerInfo[playerid][pRankScore] = PlayerInfo[playerid][pRankScore]+amount;
}

it SetPlayerRankScore not GivePlayerRankScore

help pls
xFirex is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Warning 215: expression has no effect (Need Help) Marcynka Scripting Help 10 07/09/2012 12:35 AM
[HELP]warning 215: expression has no effect Orhun_Kaya Scripting Help 1 17/06/2012 07:35 AM
warning 215: expression has no effect emp7y Scripting Help 18 11/04/2012 11:31 AM
[Help] expression has no effect - Warning. Miikkel Scripting Help 5 26/11/2011 12:35 AM


All times are GMT. The time now is 12:58 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.