The online racing simulator
Searching in All forums
(931 results)
Fire_optikz001
S2 licensed
gai, i tries this and im in the zone but it says Command not available here

any idea?


<?php 
            
CASE "!buyfood":
                IF( 
GetCurrentPlayerVar"idZone") == "Store" THEN
                    privmsg
"You Just Bought " $argv " units of food." );
                ELSE
                    
privmsg"Command not available here");
                ENDIF
                Break;
?>


<?php 
    RegisterZoneAction
"Store" "AS5" , -101,432130 Test );
?>

Last edited by Fire_optikz001, .
Fire_optikz001
S2 licensed
Quote from MariusMM :Obviously it says whatever you want it to say after how long you want.

$distToDo = [U][B][COLOR=Red]100[/COLOR][/B][/U];
Event OnDistDone( $userName ) # Player event
writeline( "[U][B][COLOR=red]100m[/COLOR][/B][/U] dist done by " . $userName . " - total dist :" . GetCurrentPlayerVar("TotDistMeter") );
EndEvent

The red is where you edit how ever long distance you want the bonus to be at.

If I haven't completely misunderstood LFS lapper ^^. (Never scripted anything with lapper...)

i can see that now

Also is it possible to store the cruise info in its own dbs? like Cruise.dbs? kinda like the drift points and such
Last edited by Fire_optikz001, .
Fire_optikz001
S2 licensed
Quote from Gai-Luron :Release 5.9.0.6 RC available for test purpose.

send me feedback.

GO! GO! GO! with cruise Script, you have everything now


+-------------------------------+
|Changes from v5.904 to 5.906 |
+-------------------------------+
1. Add new player var TotDistMeter that is the distance in meter do by a player
this value is set to 0 when a player connect to the server
You can set this value by SetCurrentPlayerVar( "TotDistMeter" , 10000 );

2. Add new config var
$distToDo = 100;
it is the amount of meter that player must do to trigger new player event OnDistDone, see below

3. Add new event triggered when a player do a certain distance
$distToDo = 100;
Event OnDistDone( $userName ) # Player event
writeline( "100m dist done by " . $userName . " - total dist :" . GetCurrentPlayerVar("TotDistMeter") );
EndEvent


:P ill start working on it now

also does it say that every 100m?

I also will need this added http://www.lfsforum.net/showthread.php?t=61328

not the savegrouptofile as u already have something like that
Last edited by Fire_optikz001, .
Fire_optikz001
S2 licensed
11/26/2009 11:41:55 AM -> Syntax error in cfg file "" at line #583
Time Out in Event or Sub 2000 ms
Function 'onconnect' script aborted
Fire_optikz001
S2 licensed
didnt think of that well i think ill start
Fire_optikz001
S2 licensed
gai, when i do !stop or any other thing ex reload insim crashes idk if its just me or weather its a bug please help
Fire_optikz001
S2 licensed
well at my demo server we dont take any actions unless...
  1. we see it our selfs
  2. multiple people agree it was that person
  3. watch replay
Fire_optikz001
S2 licensed
actually

X shift down S shift up :P
Fire_optikz001
S2 licensed
i tired this

<?php 
         
CASE "!pm":
           IF( 
$argv != "" )   THEN
            $idxSpace 
indexOf$argv" ");
                                IF( 
$idxSpace != -THEN
            $toUser 
subStr$argv,0,$idxSpace );
            
$argv trimsubStr$argv,$idxSpace ) );
          
privMsg "^6PM To " GetPlayerVar$toUser "NickName" )  );
            
privMsg "^7" $argv );            
            
privMsg$toUser "^6PM From " GetCurrentPlayer("UserName" ) );
            
privMsg$toUser $argv );
  ELSE
             
privMsg "^7Command needs 2 paremters" );
 ENDIF
 ELSE
             
privMsg "^7Command needs 2 paremters" );
 ENDIF
 BREAK;
?>

but it didnt work
Fire_optikz001
S2 licensed
Quote from Gai-Luron :Why don't you save data on a specific node or zone of the track. When a player finish lap. and then when a player leave server

i mean i can make a scedualed event but would need a way go save it to the file
Fire_optikz001
S2 licensed
well in the end im gonna have to make it count money... i was thinking im not 100% how im gonna get it to store user stats :P

i would need to make it save user stats every x minutes
Fire_optikz001
S2 licensed
aha :P well i figured out how to do that :P nice tho i didnt even think of that :P
Fire_optikz001
S2 licensed
Quote from Gai-Luron :The zone id, i think and the player var idZone. Very strange no? Yes it's only for your dev i have added this feature. I hope you release your cruise script to the community when you finish it . Please use catchevent and catchsub to have a standalone script.

@Yisc[NL]
Not many things are changed, the most important are the userName var passed to all event players, some modification in defaults script to use catchevent and catchsub, improvement of arrayvar and some builtin function can return array.

I modify some internal code too. Not visible for you, but better for me !

Thank's

yes i will release it there is one more thing i do need ... if possible a thing to count km
Fire_optikz001
S2 licensed
how to do this in the src of 5.9.0.3


<?php 
                
case "usermsg":
                    {
                        
testArgs(ident"SSS"args);
                        
currInfoPlayer listOfPlayers.getPlayerByUserName((string)args[1]);
                        if (
currInfoPlayer == null)
                            throw new 
GLScript.GLApp.GLScriptException("You can't use " ident " in this context, not a player event");
                        
string text args[2].ToString();
                        if (
text == "[[TranslateEngine]]")
                            
text lfsLang.replaceParmsLangStr(currInfoPlayer.idLang);
                        
SendMsgToConnection(currInfoPlayer.UCID"^6Personal msg from: ^8" + (string)args[0]);
                        
SendMsgToConnection(currInfoPlayer.UCID"^7" text );
                        break;
                    }  
?>

Fire_optikz001
S2 licensed
took me a few seconds to upgrade my script from 5.8.4.6
Fire_optikz001
S2 licensed
cool u added some of the stuff i needed for my cruise addon
Fire_optikz001
S2 licensed
Quote from Gai-Luron :Give me some example like
player 1 enter in zone1
Command available
player2(admin) enter in zone1
Command available

player 1 enter in zone2
Command available
player2(admin) enter in zone2
Command available

player 1 enter not in zone
Command available
player2(admin) not in zone
Command available


i don't know how work cruise server. for me it's new

Gai-Luron

:P well i mean what i have now is its spilt there is a section of admin commands and help commands then there is race/drift commands that i dont want used in cruise... u should come see al the stuff im working on
Fire_optikz001
S2 licensed
well i was gonna create a cruise part so there would be 2 areas and since i didnt want to double my script i wanted to put it in 2 sections so one was the commands that are on all the time (admin commands) the other was ones that wouldnt matter so i had 2 defaults if the command wasent in the admin it would say invalid command even if it was a real command so i needed it to store a value so that it could tell the other command area that it dont exist in the admin section meaning it would then say it only once if it was not really a command in either section
Fire_optikz001
S2 licensed
ok well when i tried it it didnt work :| im trying to set something up cause i have a full time command section and part time but i think i may trash the idea :| idk yet
Fire_optikz001
S2 licensed
Quote from Fire_optikz001 :is this

<?php 
    
IF( GetCurrentPlayerVar"command" ) == "does not exist" )
    
THEN
                                privMsg
"^1Invalid Command! ^7Please Look At ^2!Help ^7For Commands!" );
   ENDIF
?>

correct if wanted to fetch this

<?php 
 SetCurrentPlayerVar
"command","does not exist" );
?>

please help!

Bump
Fire_optikz001
S2 licensed
Quote from master_lfs.5101 :Be happy to host. PM you soon

might as well start a hosting company >.>
Fire_optikz001
S2 licensed
Quote from Andy King :Hi Gai, it remains at 100% until you reboot the machine. I left it overnight after a Lapper crash and in morning it was still at 100%. I rebooted machine and CPU was at 1-2% then started LFS and Lapper which took it up for 30 seconds and then its went back to 2-4% until it crashed. The crash has to be a Stack Type empty crash where Lapper tells you to look in the log within the dos screen.

I will try and reproduce the crash. and save all logs to show you.

:P it dont do that for me i think it might be ur pc :P
Fire_optikz001
S2 licensed
Quote from PoVo :

like the new banner too
Fire_optikz001
S2 licensed
Quote from Andy King :

Also would like to see LFSLapper with its very own icon.

i added one to Mine
FGED GREDG RDFGDR GSFDG