The online racing simulator
Release : LFSLapper V7.0.4.4
(12 posts, started )
Release : LFSLapper V7.0.4.4
Hello LFSlapper users,

I'm proud to release a new small version of LFSLapper.

+-------------------------------+
|Changes from 7.0.4.3 to 7.0.4.4|
+-------------------------------+
=================================================
New:
=================================================
1. New LapperFunction: AllowedPlayerCars($UserName,$Cars);

$UserName = Bass-Driver;
$Cars = XFG+XRT+RB4;
AllowedPlayerCars($UserName,$Cars);

2. New LapperVar: GetLapperVar("racetime");
Time will be reset after restarting the race.

Examplevideo: First test

=================================================
Update: Lappercore/Script Updates.
=================================================
1. Update Sub Callback for RegisterNodeAction() & RegisterZoneAction()

The Callback Sub for RegisterNodeAction() & RegisterZoneAction() is having a extra variable.

Example:

RegisterNodeAction( TESTID, getLapperVar( "ShortTrackName" ) , getCurrentPlayerVar("CurrNode") , test,"" );
Sub test($UserName,$ZoneID)
privmsg("ID=".$ZoneID); #output is TESTID
EndSub

Now it is possible to call this sub with differend Node/Zone actions

NOTE: Sub Callback with 1 variable will cause errors in the ERRORfiles.
NOTE: Older Scripts need to be updated
=================================================
Fixed: Lappercore fixes.
=================================================
1. Event OnAngleVelocity( $userName )
This event will now also execute with negative Angle values. (When you cars spins to the right or to the left)
Previously, only executes when car spins to the left.

2. RemoveNodeAction();
Lapper crashed when removing node with invalid NodeID.

3. RemoveZoneAction();
Lapper crashed when removing zone with invalid ZodeID.

Attached files
LFSLapper V7.0.4.4.rar - 2.2 MB - 400 views
Hi,

I made a small codechange in the RegisterZoneAction() and RegisterNodeAction().
The Callback Sub shall have a extra variable.

Example:


<?php 
RegisterNodeAction
TESTIDgetLapperVar"ShortTrackName" ) , getCurrentPlayerVar("CurrNode") , test,"" );

Sub test($UserName,$ZoneID)
   
privmsg("ID=".$ZoneID); #output is TESTID
EndSub
?>


Why this change?
Now it is possible to call this sub with differend Node/Zone actions

With this small change, all the current Sub Callbacks from the Zone/Node actions must be changed.
So many scripts will not work properly, if it has any Node/Zone action.

FROM

test($UserName);

TO

test($UserName,$ZoneID);

I've tried to ignored the warning message that checks the variables in the Sub callback, but Lapper will Crash immediately.
I'm looking for a solution to make it compatible with older versions of LFSLapper
Because on tracks X does not display the nodes?
Will not fix that in Whesthill X does not show the nodes?
X and Y tracks(open configs) does not contain Nodes: getCurrentPlayerVar("CurrNode").
Only X and Y values: getcurrentplayervar("X") and getcurrentplayervar("Y").
New version released: See first post.
Good Bass-Driver, could you please share a script where I can activate vehicles to X user?

From already thank you very much !
if you have red the changelog, you will find an example:

$UserName = Bass-Driver;
$Cars = XFG+XRT+RB4;
AllowedPlayerCars($UserName,$Cars);

Quote from Bass-Driver :if you have red the changelog, you will find an example:

$UserName = Bass-Driver;
$Cars = XFG+XRT+RB4;
AllowedPlayerCars($UserName,$Cars);


I do not understand how it would be to put the script: s
Is the code used?

CASE "!acars":
allowedplayercars($userName,$argv); #Set allowed cars to a specific player
$UserName = Enturba2-ARG;
$Cars = XFG+XRG+FBM;
AllowedPlayerCars($UserName,$Cars);
BREAK;

in a command for example
In this case you set cars for yourself

!acars XRT+RB4+FXO

CASE "!acars":
allowedplayercars($userName,$argv);
BREAK;

Soon i will make an script to select a player to set theire allowed cars.


EDIT: See post above
Both post made at the same time LOL
-
(Bass-Driver) DELETED by Bass-Driver : Not nessessary anymore
In the changes.doc file, for the Changes from 7.0.4.3 to 7.0.4.4 section, it reads

Quote : 1. Update Sub Callback for RegisterNodeAction() & RegisterNodeAction()

The Callback Sub for RegisterNodeAction() & RegisterNodeAction() is having a extra variable.

I assume that should be
Quote : 1. Update Sub Callback for RegisterNodeAction() & RegisterZoneAction()

The Callback Sub for RegisterNodeAction() & RegisterZoneAction() has an extra variable.

copy&Paste Error.

I fixed the Typo's in the first post aswell.

Release : LFSLapper V7.0.4.4
(12 posts, started )
FGED GREDG RDFGDR GSFDG