error 029: invalid expression, assumed zero -
VGAassassin - 07.08.2018
(17244) : error 010: invalid function or declaration
(17253) : error 029: invalid expression, assumed zero
(17266) : error 010: invalid function or declaration
there's is code
Код:
public OnPlayerTakeDamage(playerid, issuerid, Float: amount, weaponid, bodypart)
{
new
Float: health,
Float:armour
;
GetPlayerHealth(playerid, health); // Gets the health of the player that took damage, and stores it in the float "health".
GetPlayerArmour(playerid, armour); // Gets the armour of the player that took damage, and stores it in the float "armour".
switch(bodypart)
{
case 3: SetPlayerHealth(playerid, health - 30); // Torso.
case 4: SetPlayerHealth(playerid, health - 20); // Groin.
case 5: SetPlayerHealth(playerid, health - 5); // Left Arm.
case 6: SetPlayerHealth(playerid, health - 10); // Right Arm.
case 7: SetPlayerHealth(playerid, health - 7); // Left Leg.
case 8: SetPlayerHealth(playerid, health - 12); // Right Leg.
case 9: SetPlayerHealth(playerid, health - 50); // Head.
}
return 1;
}
public OnPlayerGiveDamage(playerid, damagedid, Float: amount, weaponid, bodypart)
the Public onplayergivedamage it's last error
Re: error 029: invalid expression, assumed zero -
VGAassassin - 07.08.2018
need help, please
Re: error 029: invalid expression, assumed zero -
Jing_Chan - 07.08.2018
Show the exact lines of error in order to be helped.
Re: error 029: invalid expression, assumed zero -
VGAassassin - 07.08.2018
Quote:
Originally Posted by Jing_Chan
Show the exact lines of error in order to be helped.
|
Re: error 029: invalid expression, assumed zero -
Jing_Chan - 07.08.2018
Quote:
Originally Posted by VGAassassin
|
The code you've provided in this is different to the first post, can you provide me the code which is causing the errors?
Re: error 029: invalid expression, assumed zero -
VGAassassin - 07.08.2018
Quote:
Originally Posted by Jing_Chan
The code you've provided in this is different to the first post, can you provide me the code which is causing the errors?
|
Re: error 029: invalid expression, assumed zero -
TadePoleMG - 07.08.2018
did you made it like this?
PHP код:
public OnPlayerGiveDamage(playerid, damagedid, Float: amount, weaponid, bodypart)
{
return 1;
}
or not?
Re: error 029: invalid expression, assumed zero -
VGAassassin - 07.08.2018
Quote:
Originally Posted by TadePoleMG
did you made it like this?
PHP код:
public OnPlayerGiveDamage(playerid, damagedid, Float: amount, weaponid, bodypart)
{
return 1;
}
or not?
|
yes i make it
Re: error 029: invalid expression, assumed zero -
TadePoleMG - 07.08.2018
provide me full error codes with error lines.
Re: error 029: invalid expression, assumed zero -
Florin48 - 07.08.2018
remove } after Float:armour and put ;