AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Problem with id (https://forums.alliedmods.net/showthread.php?t=232427)

Loupu. 12-30-2013 09:54

Problem with id
 
Hi , just another problem when try-ing to compile the plugin i got the error:
Code:

mix.sma(559) : error 017: undefined symbol "id"
mix.sma(559) : warning 215: expression has no effect
mix.sma(559) : warning 215: expression has no effect
mix.sma(559) : warning 215: expression has no effect
mix.sma(559) : warning 215: expression has no effect
mix.sma(559) : error 001: expected token: ";", but found ")"
mix.sma(559) : error 029: invalid expression, assumed zero
mix.sma(559) : fatal error 107: too many error messages on one line

This the line:
Code:

client_print(id, print_chat, "%L", LANG_PLAYER, "MINI-ACE WAS REGISTERED!")
And this the code:
Code:

                    if (g_KillsAce[tempid] == 4)
                    {
                        new name[32]
                        get_user_name(tempid, name, 31)
                   
                        client_print(0, print_chat, "%L", LANG_PLAYER, "did an MINI-ACE", name)
                        client_print(id, print_chat, "%L", LANG_PLAYER, "MINI-ACE WAS REGISTERED!")
                    }


Kia 12-30-2013 09:55

Re: Problem with id
 
Use tempid, not id.
Also, this is not how you use Multi-language.

PHP Code:

client_print(tempidprint_chat"%L"LANG_PLAYER"MINI-ACE WAS REGISTERED!"

->
PHP Code:

client_print(tempidprint_chat"%L"LANG_PLAYER"MINI_ACE_MADE"

Then in your multi-language file.

Quote:

[en]
MINI_ACE_MADE = "You made a mini-ace."

YamiKaitou 12-30-2013 09:55

Re: Problem with id
 
Undefined symbol means you are using a variable that doesn't exist. Either define it or change it


All times are GMT -4. The time now is 10:08.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.