Can you post a couple of screenshots of what is happening?
To close a button in Lapper, the ID of that button is used.
Maybe the close routine isn't refering to all the correct ID's.
Make a copy of the LPR file, then rename that copy to .txt and upload it to the forum as well.
Hello, is there anyone who could explain to me why this one works
IF (MSHToNum(GetUserStoredValue( $userName."Sector3" )) > 29170) THEN PrivMsg("test"); ENDIF
but these two options don't?
IF (MSHToNum(GetUserStoredValue( $userName."Sector3" )) > 29170 || MSHToNum(GetUserStoredValue( $userName."Sector3" )) < 40000) THEN PrivMsg("test"); ENDIF
IF (MSHToNum(GetUserStoredValue( $userName."Sector3" )) > 29170) THEN IF (MSHToNum(GetUserStoredValue( $userName."Sector3" )) < 40170) THEN PrivMsg("test"); ENDIF ENDIF
Well, I will be honest with you, a lot is wrong with your code.
You messed up commands and you didn't used the catchevent properly.
So I have re-arranged and corrected your code.
I've only tested it to see if it runs without errors now (which is the case), but haven't tested if it does what you want it to do.
- Download the file
- Rename it to sector_times3.lpr
- Put it in the "includes" folder
Could you explain your code, so that we understand what it must do.
Because what Yisc[NL] siad, there are alot of faults in your script (what i can see in a quick view).
Thank you, sorry I probably should have clean it up before attaching.. Well I used your corrected version and it works just fine. I still don't really understand how did I use catchevent wrong.. is it because I did not use Sub? Anyway I'm happy, thank you for your help
The toplist you see is not finished yet.
several functions has to be added.
2 other questions:
-Is it possible that "cleanspb" doesnt work. because my record is still there.
-I'm running an timeattack challenge on my server. It's recording times without penalty's.
Example: laptime: 1:00:00 and Penalty is 30 seconds. so totaltime should be 1:30:00. But its recording the 1:00:00. Is there a easy fix for it?
i know there is something like: $flagConfirm. Does it have effect about the storing the laptimes?
It could well be the case that cleanspb doesn't work, although I think it's not related to a recorded time, but only to the best time in that particular session.
Documententation says this about it: /cleanspb -> Clean your current session of Spb
A while ago I had a struggle with flagconfirm and then finaly found out how that is working.
First you need to know this:
Of course the actions within each IF-statement, are of no use for you, but you can replace them with the things you want to happen.
And no, this won't have effect on the laptimes that Lapper will record, so you need to start storing your own values.
Maybe it is a stupid question, but i need to know something.
I'm rewriting the dragscript, so that demousers can use the script.
It's because demousers cannot use AutoX editor for placing "Splits", so they must use tracknodes.
To get the time i can use: getLapperVar( "LongTime" ). But is there a Variable that can get the current laptimer? to get milliseconds.
There is a variable to get the laptime: LapTime
And there's a function to get milliseconds: NumToMs
Although it's earlier called "NumToMSH" in the changelog.
According to changes.txt two variables are written in lower case only:
6. Added 3 new var setted at end of race or qualification
finishedpos : finish or qualify pos (1 = win / 256 = not added to table)
racetotaltime : race time (ms) use NumToMsh is need
racepbtime : race time (ms) use NumToMsh is need
Sadly this has happened a lot in Lapper, as either the use of variable names in inconsistent and/or the documention is incorrect.
Recently I had to go through the source files to get the correct spelling for a variable.
It also looks like that "racetotaltime" and "racepbtime" are only set at end of race or qualification.
Longtime always seems to be in 12-hour format and setting "TimeFormat = HH:mm;" in the Lapper server config file, makes it crash, so although it's mention in the chances.txt, it doesn't work.
In the end I came up with this script, althoug I doubt if this is enough to measure time for drag racing, since it can only handle full seconds:
Thanks, why didnt i came up with this LOL.
Never thought that SplitToArray() could work on lapperVars. Because i used SplitToArray() alot in my logfile scripts.
Anyway, i go play with the code and see if i can get it to work in my dragscript. Its something to measure the time between nodes etc.
when reading through 'changes.txt' I see this about groupcmdlfs:
groupCmdLfs( cmd );
Same command as cmdLfs but send this LFS command to all server having the same group id.
So basicly it let you do the same actions that can be used in 'cmdLfs' but then for the whole group.
As far as I can see, there isn't a way to retrieve information from another instance of Lapper.
Of course you could write some values to the database and then retrieve them from another server.
I've used such thing in my schedule and schedule_set script, so you might want to have a look at those scripts.
Anyway, i go back to 1 lapper per server. Otherwise i have to change the code of several systems.
For example i'm updating my adminpanel. The logfiles are not stored in the database. Here's a picture of it. It works good and as admin you have a sort of control over your admins/server.
As soon as any event within Lapper is triggered, you can use the several variables within that event, to do different things.
You can do that as in your example, but it's even possible to combine variables and do different things.