The online racing simulator
Lapper language error
Hello users. have problem. maybe somebody know where try find problem?


Event OnConnect( $userName ) # Player event

$NickName = GetCurrentPlayerVar("NickName");
$Posabs = GetCurrentPlayerVar("PosAbs");
$Groupqual = GetCurrentPlayerVar("GroupQual");
openPrivButton( "welc",25,50,150,15,12,-1,ISB_NONE, langEngine("%{main_welc1}%", $NickName ) );
openPrivButton( "pos",25,80,150,10,8,-1,ISB_NONE,langEngine("%{main_welc2}%",$Posabs,$Posqual,$Groupqual ) );
openPrivButton( "clos",78,120,20,10,10,-1,ISB_DARK,langEngine("%{main_accept}%"),OnConnectClose );
openPrivButton( "ref",103,120,20,10,10,-1,ISB_DARK,langEngine("%{main_deny}%"),OnConnectCloseKick );


$RaceTime = GetLapperVar("racetime");
EndEvent

Sub OnConnectClose( $KeyFlags,$id )
closePrivButton("welc&pos&clos&ref");
EndSub

Sub OnConnectCloseKick( $KeyFlags,$id )
closePrivButton("welc&pos&clos&ref");
cmdLFS("/kick " . GetCurrentPlayerVar("UserName") );
EndSub


Lang "EN"
main_welc1 = "^7Welcome {0} ^7to server created by BenickisLT! %nl%^2Type ^7!teleport ^2after leaving garage to see spots menu.";
main_welc2 = "!! Use only RWD cars !!%nl%Don't use swearwords on this server%nl%respect other player%nl%otherwise you can be banned";
main_accept = "Accept";
main_deny = "Deny";
main_speedtrap = "SpeedTrap = {0} {1}";
main_gotlevel = "^3You have got level: {0}";

Attached images
New Bitmap image.jpg
New Bitmap imagasde.jpg
Hello bro, Lang "EN" you need close it EndLang

Like this:

Lang "EN"
main_welc1 = "^7Welcome {0} ^7to server created by BenickisLT! %nl%^2Type ^7!teleport ^2after leaving garage to see spots menu.";
main_welc2 = "!! Use only RWD cars !!%nl%Don't use swearwords on this server%nl%respect other player%nl%otherwise you can be banned";
main_accept = "Accept";
main_deny = "Deny";
main_speedtrap = "SpeedTrap = {0} {1}";
main_gotlevel = "^3You have got level: {0}";
EndLang
Hello,
Can you try the code below, 'main_welc2' had 3 arguments which you didn't defined in Lang "EN". Maybe that coule be the reason

you had:
openPrivButton( "pos",25,80,150,10,8,-1,ISB_NONE, langEngine("%{main_welc2}%",$Posabs,$Posqual,$Groupqual ) );

i've changed it to
openPrivButton( "pos",25,80,150,10,8,-1,ISB_NONE, langEngine("%{main_welc2}%"));

And indeed what TxilyZ said, EndLang is missing in the code.
Try TxilyZ's solution first before you try mine Smile


Event OnConnect( $userName ) # Player event

$NickName = GetCurrentPlayerVar("NickName");
$Posabs = GetCurrentPlayerVar("PosAbs");
$Groupqual = GetCurrentPlayerVar("GroupQual");
openPrivButton( "welc",25,50,150,15,12,-1,ISB_NONE, langEngine("%{main_welc1}%", $NickName ) );
openPrivButton( "pos",25,80,150,10,8,-1,ISB_NONE, langEngine("%{main_welc2}%"));
openPrivButton( "clos",78,120,20,10,10,-1,ISB_DARK, langEngine("%{main_accept}%"),OnConnectClose );
openPrivButton( "ref",103,120,20,10,10,-1,ISB_DARK, langEngine("%{main_deny}%"),OnConnectCloseKick );


$RaceTime = GetLapperVar("racetime");
EndEvent


FGED GREDG RDFGDR GSFDG