The online racing simulator
Good Config on LFSLapper for drifting?
Does anyone have a good setup for LFSLapper, drifting. I got a problem where the scores get lost when doing great drifts, but I dont really get the Angle stuff and such.
#================#
#Drifting options#
#================#

$DriftDatabase = "./DriftPB.txt";

Event DriftPBAction()
cmdLFS( "/rcm " . $Nickname . "^3 made new PB: ^7" . $DriftScore . " ^3pts!" );
cmdLFS( "/rcm_all" );
EndEvent

Event DriftPBAction()
cmdLFS( "/msg " . $Nickname . "^3 made new PB: ^7" . $DriftScore . " ^3pts!" );
EndEvent

Event DriftLapAction()
cmdLFS("/msg " . $Nickname . " ^3drifted to ^7" . $DriftScore . " ^3pts" );
EndEvent

Event OnDriftScore()
privMsg( "Score: ^7" . $DriftScore . " ^3" . $LastDriftScore );
EndEvent

$GoodDriftScore = 2500; # Value to be reached to execute action on good drift score
####### you can change the 4000 to anything you want - higher or lower number to suit


Event GoodDriftAction()
privMsg( $Nickname . " ^3made excellent drift: ^7" . $LastDriftScore ." ^3pts" );
EndEvent


$MinimumDriftScore = 10; # Minimum drift score required
####### you can change the 250 to anything you want - higher or lower number to suit

# Actions to do at end of lap if MinimumDriftScore is not achieved.
Event DriftTooLowAction()
privMsg( $Nickname . "^3 disqualified" );

cmdLFS( "/spec " . $Nickname };
EndEvent

$MinimumDriftSpeed =20; # Minimum speed in km/h to maintain. Driving below that speed will reset score
$MinimumDriftAngle =15; # Minimum angel to maintain. When angle is below value, score is reset
$MaximumDriftAngle =100; # Maximum angel to maintain. When angle is above value, score is reset
Anything wrong in here? ALso if you have a good config, please give it to me, because I cant seem to figure it out
One thing i have noticed with this is the missing--> + symbol

Its in the Event OnDriftScore()

Should be like


Event OnDriftScore()
privMsg( "Score: ^7" . $DriftScore . " ^3+" . $LastDriftScore );
EndEvent


That way its adding up the scores....
Anyone Else's opinion would be gratefully appreciated here too thanks
Hi,

This one is working on my test server. i added the missing + that Blackknight555 noticed and there was a space missing too in the GoodDriftAction() part.

#================#
#Drifting options#
#================#

$DriftDatabase = "./DriftPB.txt";

Event DriftPBAction()
cmdLFS( "/rcm " . $Nickname . "^3 made new PB: ^7" . $DriftScore . " ^3pts!" );
cmdLFS( "/rcm_all" );
EndEvent

Event DriftPBAction()
cmdLFS( "/msg " . $Nickname . "^3 made new PB: ^7" . $DriftScore . " ^3pts!" );
EndEvent

Event DriftLapAction()
cmdLFS("/msg " . $Nickname . " ^3drifted to ^7" . $DriftScore . " ^3pts" );
EndEvent

Event OnDriftScore()
privMsg( "Score: ^7" . $DriftScore . " ^3+" . $LastDriftScore );
EndEvent

$GoodDriftScore = 2500; # Value to be reached to execute action on good drift score
####### you can change the 4000 to anything you want - higher or lower number to suit


Event GoodDriftAction()
privMsg( $Nickname . " ^3made excellent drift: ^7" . $LastDriftScore . " ^3pts" );
EndEvent


$MinimumDriftScore = 10; # Minimum drift score required
####### you can change the 250 to anything you want - higher or lower number to suit

# Actions to do at end of lap if MinimumDriftScore is not achieved.
Event DriftTooLowAction()
privMsg( $Nickname . "^3 disqualified" );

cmdLFS( "/spec " . $Nickname };
EndEvent

$MinimumDriftSpeed =20; # Minimum speed in km/h to maintain. Driving below that speed will reset score
$MinimumDriftAngle =15; # Minimum angel to maintain. When angle is below value, score is reset
$MaximumDriftAngle =100; # Maximum angel to maintain. When angle is above value, score is reset


FGED GREDG RDFGDR GSFDG