25.07.2017, 16:09
I followed up everything as instructed but for some reason y_text can't read the text and, to top it, stucks in some kind of infinite loop that freezes the server, only option to pkill -9 samp03svr.
Directory structure
Loading text:
I know you are able to complain that "line X is missing" so I will give you the full example GM:
TDM.pwn: https://pastebin.com/UuDA0KrE
mensajes.EN: https://pastebin.com/jcxZb3h1
mensajes.ES https://pastebin.com/rCPVdrNt
I have a macro for "Text_DialogBox" that will add "using callback" so I don't have to type it again and again and again.
Result (log):
Last line of the log repeats flooding the server log until I kill the server.
I simply don't know what went wrong there. I'm trying to use this because it's the only implemented way to switch languages but I keep encountering nonsense like this. Please help!
Directory structure
Код:
- gamemodes | |- TDM.amx - scriptfiles | |- YSI |- mensajes_LANG_DATA.yml |- text | |- mensajes.ES |- mensajes.EN
PHP код:
new
Language:gLEspanol,
Language:gLEnglish;
loadtext mensajes[todoxd];
public OnGameModeInit()
{
gLEnglish = Langs_Add("ES", "Espaсol");
gLEnglish = Langs_Add("EN", "English");
}
public OnPlayerConnect(playerid)
{
Langs_SetPlayerLanguage(playerid, gLEspanol);
Text_MessageBox(playerid,using callback DialogIdiomaR, $TITULO_SELECCION_IDIOMA, $SELECCION_IDIOMA, $IDIOMA_ESPAСOL, $IDIOMA_INGLES);
TDM.pwn: https://pastebin.com/UuDA0KrE
mensajes.EN: https://pastebin.com/jcxZb3h1
mensajes.ES https://pastebin.com/rCPVdrNt
I have a macro for "Text_DialogBox" that will add "using callback" so I don't have to type it again and again and again.
Result (log):
Код:
[15:40:41] Text_Render: Loop: p = 14, llen = 49, output = "Text Not Found" [15:40:41] Text_Render: Final render? [15:40:41] Text_Render: Yes! [15:40:41] Text_Render: p = 14, output = "Text Not Found" [15:40:41] 00000054 = T [15:40:41] 00000065 = e [15:40:41] 00000078 = x [15:40:41] 00000074 = t [15:40:41] 00000020 = [15:40:41] 0000004E = N [15:40:41] 0000006F = o [15:40:41] 00000074 = t [15:40:41] 00000020 = [15:40:41] 00000046 = F [15:40:41] 0000006F = o [15:40:41] 00000075 = u [15:40:41] 0000006E = n [15:40:41] 00000064 = d [15:40:41] Text_Render end [15:40:41] Text_GetText: loop1 mode_text:all 0 -1 mode_text:all 109
I simply don't know what went wrong there. I'm trying to use this because it's the only implemented way to switch languages but I keep encountering nonsense like this. Please help!