The online racing simulator
Release: LFSLapper V7.0.6.0


Hello Lapperusers.

We are proud to present to you a new version of LFSLapper: V7.0.6.0

Many thanks to LakynVonLegendaus for helping me with updating this addon.

See the changelog below for the changes/fixes and ofcourse the new stuff.

NOTE:If you want some "LapperScript" example codes about one of the changes below. Request it in this topic.

+---------------------------------------------------------------+
|Changes from 7.0.5.0 to 7.0.6.0 |
+---------------------------------------------------------------+
=================================================
New:
=================================================
1: New LapperFunction: CreateDirectory();
$Source = "C:\Users\Danny\Desktop";
$Name = "TestDir";
CreateDirectory($Source,$Name);

2: New LapperFunction: DeleteDirectory();
$Source = "C:\Users\Danny\Desktop";
$Name = "TestDir";
DeleteDirectory($Source,$Name);

3: New LapperFunction: DirectoryExist();
$Source = "C:\Users\Danny\Desktop";
$Name = "TestDir";
IF (DirectoryExist($Source,$Name) == 1) THEN
privmsg("Directory Exist!");
ELSE
privmsg("Directory does not Exist!");
ENDIF

#New Math Functions:
4: New lapperfunction: Cos(); #Calculate Cos
5: New lapperfunction: Sin();
6: New lapperfunction: Tan();
#Examples:
$cos = Cos(66);
$sin = Sin(66);

$angle = 30;
$Pi = 3.14;
$Radians = $angle * ($Pi/180);
$tan = Tan($Radians);

privMsg("Cos: " . $cos);
privMsg("Sin: " . $sin);
privMsg("Tan: " . $tan);

7: New debugoptions in LFSLapper.LPR # Will be displayed in you lapper console.
-$DisplayGetPlayerVar = 0; #Display GetPlayerVars
-$DisplaySetPlayerVar = 0; #Display SetPlayerVars
-$DisplayLapperVar = 0; #Display LapperVars
-$DisplayLapperFunction = 0; #Display LapperFunctions

8: New LapperFunction: GetLytSelection(); # Request info about objects selected in layout editor - response is seen in OnObjectInfo event with $Action 5

9: New LapperFunction: SetLytSelection(); #Place objects to clipboard or select them.
CASE "!setsel":
# X:Y:Z:Flag:Index:Heading,X:Y:Z:Flag:Index:Heading,...
$obj_L = "-244.25:-1282.62:17:1:178:0,-244.25:-1282:16.75:229:178:0";
$obj_A = "-244.25:-1281.88:16.5:33:178:-180,-244.25:-1281.56:17:9:178:0,-244.25:-1281.25:16.5:33:178:0";
$obj_PP = "-244.25:-1280.12:16.5:1:178:0,-244.25:-1279.88:17:25:178:0,-244.25:-1280.69:17:25:178:0,-244.25:-1280.94:16.5:1:178:0";
$obj_E = "-244.25:-1279.19:16.75:1:178:0,-244.25:-1278.69:17:225:178:0,-244.25:-1278.62:16.5:225:178:0,-244.25:-1278.69:17.5:245:178:0";
$obj_R = "-244.25:-1278.44:16.5:1:178:0,-244.25:-1278.19:17:25:178:-180,-244.25:-1277.88:16.5:65:178:0";

$objects = $obj_L.",".$obj_A.",".$obj_PP.",".$obj_E.",".$obj_R;
$PMOFlag = 0; # PMOFlag 0 -> clipboard selection, PMOFlag 4 -> select placed objects
SetLytSelection($PMOFlag,$objects);
BREAK;
=================================================
Changed:
=================================================
1: GetListOfLayout(); will display all the layouts instead of only the layouts of the current track
2: Soundoption for globalmsg(); / privmsg();
NOTE: is compatible with older scripts.

0 = No Sound
1 = Message Sound
2 = SystemMessage Sound
3 = InvalidKey Sound
4 = ERROR Sound
5 = NUM Sound

-Possible options for globalmsg() :
globalmsg("BLAHBLAH");
globalmsg("BLAHBLAH",0);
-Possible options for privmsg() :
privmsg("BLAHBLAH");
privmsg("BLAHBLAH",0);
privmsg($userName,"BLAHBLAH");
privmsg($userName,"BLAHBLAH",0);

3: X and Y playervars now returns Floating values: -123.45 instead of rounded -123
4: JoinRequest(); allows now floating X and Y values. See the line above.
5: RegisterZoneAction() allows floating X and Y values.
6: Event OnObjectInfo() New way for displaying Object info. See Code Example in LFSLapper.LPR

Old: OnObjectInfo($userName,$NumO,$Action,$X,$Y,$Z,$Flags,$Type,$InDex,$Heading)
New: OnObjectInfo($userName,$NumO,$Action,$ObjectsInfo)

=================================================
Fixed:
=================================================
1: Lappercrash when a non existing folder is added in addonused.lpr Include().
2: Path of several script in addonsused.lpr were wrong.
3: PlayerVars couldnt be used in OnDisconnect Player event.
4: Japanese Charbug
5: HTTP(); A Host or other invalid player couldnt send a webrequest.
6: Connectioninfo(); Must to execute this function twice after reloading lapper to set the playervars ( language,IP)
7: Lappercrash when a $var is placed outside a sub or (Catch)event
8: NON-admins couldnt add/remove objects since the last LFS Version
9: Typo in hardcoded objectslist.
10: Event OnObjectInfo didnt displayed floating values.
11: AddObject()/RemoveObject() doesnt work when input values have 1 digit behind the comma. (XX,5 instead of XX,50)
12: GetLapperVar("RaceTime") could increase CPU usage when use it in a loop.
=================================================
Removed:
=================================================
1: AFK/IDLE Timer playervar ( randomly stopped working)

Attached images
DoesNotExist.jpg
japChar.jpg
laplogo_05_small.jpg
Lapperfunctions.jpg
Lapperobjects.jpg
Attached files
LFSLapper V7.0.6.0.zip - 6.4 MB - 301 views
Finally some much needed fixes. Thanks a bunch! Smile
Congrats on the new release guys.
Great to see this program still being worked on and being improved.
This version is fabulous başarılı çalışma Thumbs up

FGED GREDG RDFGDR GSFDG