Handicap and checking on tyre types, isn't the same.
But Lapper also has a section to check which tyre types are fitted.
But Lapper also has a section to check which tyre types are fitted.
#Create a textfile with the name IsInTeam and place this in your includes folder
#Enter the usernames of your team
#Here's an example how the insim checks the tag:
#I enter the server with the following nickname [MD]driver
UserGroupFromFile( "IsInTeam", "includes/IsInTeam.txt" );
$tag = substr( GetCurrentPlayerVar("NickName"),0,4 ); #Start at the beginning ( 0) and cut everything after the 4th character $tag = "[MD]";
IF(($tag == "[MD]")THEN
IF( UserInGroup( "IsInTeam",GetCurrentPlayerVar("UserName")) != 1 )) THEN #this line will check if the username exist in the file you created. IF NOT: goto next line , else abort script.
privmsg("^1You're not allowed to wear this tag!!");
privmsg("^1Pls change your name!!");
ENDIF
ENDIF
<?php
3/20/2013 1:17:45 PM -> Unexpected function in event :OnConnect on file : ".\default\.\includes\.\MD.lpr" at line #34
3/20/2013 1:27:54 PM -> Syntax error in cfg file ".\default\.\includes\.\racecontrol.lpr" at line #85
?>
Event OnConnect( $userName ) # Player event
UserGroupFromFile( "IsInTeam", "includes/IsInTeam.txt" );
#Create a textfile with the name IsInTeam and place this in your includes folder
#Enter the usernames of your team
#Here's an example how the insim checks the tag:
#I enter the server with the following nickname [MD]driver
$tag = substr( GetCurrentPlayerVar("NickName"),0,4 ); #Start at the beginning ( 0) and cut everything after the 4th character $tag = "[MD]"
#privmsg("".$tag);
IF($tag == "[MD]")THEN
IF( UserInGroup( "IsInTeam",GetCurrentPlayerVar("UserName")) == 0 ) THEN #this line will check if the username exist in the file you created. IF NOT: goto next line , else abort script.
privmsg("^1You're not allowed to wear this tag!!");
privmsg("^1Pls change your name!!");
ENDIF
ENDIF
EndEvent
CatchEvent OnMSO( $userName, $text ) # Player event
$idxOfFirtsSpace = indexOf( $text, " ");
IF( $idxOfFirtsSpace == -1 ) THEN
$command = $text;
$argv = "";
ELSE
$command = subStr( $text,0,$idxOfFirtsSpace );
$argv = trim( subStr( $text,$idxOfFirtsSpace ) );
ENDIF
SWITCH( $command )
CASE "!setzone":
SetZone(GetCurrentPlayerVar("X"),GetCurrentPlayerVar("Y"));
BREAK;
ENDSWITCH
EndCatchEvent
Sub Zone( $userName )
#Code when user drive throught the zone
EndSub
Sub SetZone($NewXNode,$NewYNode)
RegisterzoneAction( getLapperVar( "ShortTrackName" ), $NewXNode,$NewYNode,1, Zone, "");
EndSub