AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   help with a line (https://forums.alliedmods.net/showthread.php?t=319083)

Mankled 10-09-2019 23:21

help with a line
 
how can i put lang in this line

PHP Code:

menu_setprop(MenuMPROP_BACKNAME"Back"

to like this:
ex:
PHP Code:

client_print(0print_chat"%L"LANG_PLAYER"RESULT_REF"


instinctpt1 10-10-2019 01:13

Re: help with a line
 
By providing a formatex() before the menu_setprop()

Mankled 10-10-2019 01:48

Re: help with a line
 
it gave me a error:
PHP Code:

formatex(menu_setprop(MenuMPROP_EXITNAME"%L"LANG_PLAYER"EXIT"


PHP Code:

Welcome to the AMX Mod X 1.8.1-300 Compiler.
Copyright (c1997-2013 ITB CompuPhaseAMX Mod X Team

Error
Argument type mismatch (argument 1on line 177

1 Error
.
Could not locate output file C:\Users\mank\Desktop\pluginmenu.amx (compile failed). 


LearninG 10-10-2019 03:45

Re: help with a line
 
Code:
new szText[10] formatex(szText, charsmax(szText), "%L", LANG_PLAYER, "EXIT") menu_setprop(Menu , MPROP_BACKNAME , szText)

OciXCrom 10-10-2019 13:55

Re: help with a line
 
Check the API if you're not sure about a function's arguments.
If you're using AMXX 1.9+, you can do everything in one line by using the "fmt" function.


All times are GMT -4. The time now is 02:43.

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