The online racing simulator
Searching in All forums
(482 results)
Scawen
Developer
Good point, I think those options (fee and prize) are not needed and as they are never displayed, I have removed them from the league edit page.

If a league has prizes or entry fees, the organisers can express that in text somewhere.
Scawen
Developer
I think all points have been made and I will now close this thread.

This is a game for entertainment and users should not use images or words with negative connotations for other users, even if the perception is different in different cultures.

The idea is we should all get along in Live for Speed, without culture battles. LFS is a place where people from around the world can get together.

Addressing the point of this thread, I would like to emphasise that the incident described was not a discrimination against Islamic culture. We have many Turkish and Islamic players who are very welcome.

All cultures are welcome in Live for Speed, along with their customs. This is part of the point of the game, the good it can do in the world. Let's all make sure we are not upsetting people in different cultures.

Thank you.
Scawen
Developer
I thought I would write a summary of the on-site entry system, for anyone who is interested. I list the features and recent updates. I might post this list somewhere else, maybe the leagues section. Please let me know if I've missed some important features to mention, or if my description is unclear. I still want to add one feature, for admins to be able to send a message to all racers who are signed up.


On-site entry system for league seasons or individual rounds

Additional administrators can be specified by the owner of the league
Admins can setup a customised race entry format, for individual or team entries
Entries can be set to be for the whole season or for individual rounds
Round or season entries can be seen by anyone who visits the round or season page
Any number of required fields may be set, per team or per racer (e.g. name, country, number, etc)
For team-based entries, a maximum team number can be set
An opening and closing time for entries can be specified
There is an option for entries to require approval by an admin
Entries can be deleted by an admin (or the person who signed up)
The person who signed up can edit their entry at any time or remove or add team members
Admins can download a CSV file containing the info of all entrants, to paste into a spreadsheet


Recent updates:

Website:
Removed "Racer 1" display above every racer if set to 1 racer per entry (not team entry)
Now possible to remove a signup entry (from season or round signups) on signup edit pages
For signup per round, added button to sign up for round, on the round signups info page
FIX: Information about round signups was not visible on the individual round details page

Admin:
Download a CSV file containing the info of all entrants, to paste into a spreadsheet
FIX: Signup options appeared on "Edit Season" when set to "No Signup" or "Invite only"

In-game:
In-game signup link now goes to season or round info page instead of direct to signup
Removed "Sign up" button from in-game event list if the season is set to "Invite only"
Scawen
Developer
More updates and fixes for the on-site signup system:

Now possible to remove a signup entry (from season or round signups) on signup edit pages

FIX: Information about round signups was not visible on the individual round details page

For signup per round, added button to sign up for round, on the round signups info page

In-game signup link now goes to season or round info page instead of direct to signup
Scawen
Developer
Minor updates:

FIX: Signup options appeared on "Edit Season" when set to "No Signup" or "Invite only"

Removed "Sign up" button from in-game event list if the season is set to "Invite only"

Removed "Racer 1" display above every racer if set to 1 racer per entry (not team entry)
Scawen
Developer
About entering races using our on-site entry system, there is one 'feature' I think is missing.

If I enter as someone who is not a league admin, I can't find any way to remove my entry. I can edit it, and remove extra team members of a team entry, but not remove the whole entry.

As a league admin I can remove a whole entry from my season or round but I think this quite important option is missing for non-admins.


EDIT: Fixed this, now you can remove your entry. https://www.lfs.net/forum/post/2113416#post2113416
Last edited by Scawen, .
Scawen
Developer
Thanks, I've seen a screenshot like this from our database before but I don't have access.

I've only been able to make database changes directly through SQL queries (which I have done quite a lot in the past year).

I will ask Victor if he can give me access as it could be useful for adding fields or editing a value manually.
Scawen
Developer
Nice one, thanks, fixed now.
Scawen
Developer
Quote from r3zp3k7 :...some events are missing description, when you open them...

Thanks for the suggestion. I've now made it so that if there is no season description, then the league description is used.

Quote from Flame CZE :In the weekly calendar overview, if the event description is missing, the season description is used, if that's missing too then the league description is used. https://www.lfs.net/leagues/810

Close but in fact rounds don't have a description field, so it's just season description, and if not then the league one.

Quote from tankslacno :So league admins might need the possibility to add a description for each round individually. Especially if rules for that one round are significantly different compared to the others. So, the possibility to add a description for each round individually would solve most needs.

This is a good idea but I haven't yet graduated to adding new fields to the database tables. Of course, Victor could be called upon to add an optional round description, or I could in future when my skills are up a little more.
Scawen
Developer
As I don't know anything about REST, and I'm not even a web developer by trade (and Victor isn't an active LFS developer at this time) that is way beyond the scope of what I could do. My question is more about if there is something I could add in an hour or two, for league admins who could nearly use our on-site signup system but it's just missing something small that they need.
Scawen
Developer
One more feature, if you use the on-site signup system, you can now export a CSV of all the racer details.

The CSV comes out something like this:

"Scawen","S Roberts","LFS Devs","37","England"
"Leo","L. Roberts","Coders","77","Wales"

I think the signup system Victor made is quite good and has a lot to it, but unfortunately it is rarely used, partly because it misses a few features (discussed earlier in this thread).

I was able to add this CSV output quite simply. The other thing that seems important and simple is for the race organiser (league admins) to be able to send a PM to all signed up racers.

For anyone unfamiliar with this, you can see in the attachment, you can add any required fields. Then there is an on-site signup and everyone can see who has entered.

Questions, to anyone who might use the on-site signup, now or if it is improved a bit more:

- Is the CSV output adequate for your needs?
- What other features are necessary to make this system more convenient than your existing methods?
Scawen
Developer
I've added a "Time zone" display in account settings: https://www.lfs.net/account/settings

You can see what the server thinks your offset is.

The result is:
- if I change my time zone, that offset is unaffected (even refresh page)
- exit the browser and go back to that page, offset is still at old time zone
- log out from LFS.net and lock back in, my new time zone offset is acquired

As far as I can tell, this only affects calendar display and something to do with poll expiry times, so I think it's not worth further investigation.
Scawen
Developer
No, not about formatting the string, I just want to know the actual offset of the client's computer compared with UTC. It seems our website knows that already but it isn't updated if I change my computer's time zone.

EDIT: Maybe it's cached and gets corrected after a while, I don't know. I suppose it's a bit complicated because the php is of course running on the server but we are talking about the client computer's time zone, so perhaps that isn't readily available on the server.

OK I think I'm starting to get the picture, it must be updated by the ajax request, as Flame said though that's not something I am familiar with yet. I suppose there is a mechanism for the client computer to inform the web server of its timezone, but we don't want to do that all the time.

EDIT2: Maybe it's not a bug at all. Maybe LFS website just isn't very quick to get the timezone right if the client adjusts their time zone. But it would be good to know if it eventually gets corrected.
Last edited by Scawen, .
Scawen
Developer
Thanks, I can reproduce that and will check it out tomorrow. I didn't realise the leagues system had quite a few bugs in it! Apparently in this case it prepares that list of tracks but doesn't specify which one is selected, so that information is lost when you submit the form.

EDIT: That is fixed now. This bug was newly introduced by me. It was caused when I changed a short track name function to display correctly on the calendar (e.g. SO2R). I didn't realise the same function was used internally for track name comparisons. I've restored the old function and added a new one for the calendar.
Last edited by Scawen, .
Scawen
Developer
Thanks a lot for your help.

I guess it's worked out at some point then stored in the session variables.

So not really a bug, but it just doesn't deal well with windows changing time zone (even if I restart the browser).

I'm not sure if there's a better way to do it, or a more standard way to do it. Maybe the time offset is readily available in a php function so we don't really have to go through all this confusing code?
Scawen
Developer
Yeah I've been looking around, it's pretty hard to unpick as there are a lot of functions calling others and conditional interactions between javascript and php.

It's too complicated for me now as long past my bed time. Trying to figure out other people's code isn't my favourite task. Maybe I can unpick this stuff a bit tomorrow.

But can I ask one question, is that session variable correct for you? I mean... do you see the calendar on the correct day, i.e. moving into the next day as the "current day" before UTC is actually at that day? Just wondering if my offset is zero because that is sort of in my session already, so it's not "tricked" by me changing the Windows time zone.
Scawen
Developer
I see... or I think I understand what you are saying but I still don't really understand why it worked fine on my computer. Uhmm

For further confusion, and answering your question, I was able to manually adjust the time using a value called LFS::$session->vars['timeOffset'] which I understand to be a time zone offset.

But I'm not really sure what's happening now, as it seems sometimes that offset is set to zero, even though I have set a different time zone in Windows. It comes from a $_GET['t'] value at some point.

That offset being zero seems to be why my calendar still shows me in Thursday when my timezone is actually UTC+1 at the moment.
Scawen
Developer
OK, I've changed it to follow the convention.

But I don't see the harm in initialising with the already converted time, it seems to me that it just avoids a 1 frame glitch when you reload the page.

When initialising with the UTC text, it is at first visible at UTC then a split second later changes to the local time for the selected timezone.

EDIT: I've found that it still thinks I am in Thursday, even though I set my timezone to UTC + 1 and that is really Friday now... looking into it...
Last edited by Scawen, .
Scawen
Developer
Nice detective work there! I've reinstated the original code now without the "bold" and fixed the same issue in another few places.
Scawen
Developer
Maybe your browser has a bug with data-format="time" ?

Instead of relying on that time tag I've now coded it manually instead, so I think it should work for you now.
Scawen
Developer
Oh, that is strange. It looks fine to me in Firefox if I go to UTC+1 timezone (the UTC hover text is an hour off from the visible text). I did have to refresh the page after changing time zone but then it looked correct.

It uses an html <time> element which in my browser shows local time normally but UTC time when hovering. It's the same with these forum post times (Today: 21:15) etc.
Scawen
Developer
I hope all the time zone stuff works properly, it's always confusing to implement and made my day's task a lot harder. Especially when we are dealing with things displayed near day and month boundaries, and must be placed and displayed in the correct day slot, and the viewer can be in any time zone, at any time, and select any month or week to view.

I'd obviously like to know if there are any errors with time zones.

A simple test is if someone could compare the in-game event browser with the website calendar and make sure it looks correct. Hovering over the event time should show the UTC time, in case that is useful.

One test I should do is set my timezone to somewhere far from UTC and confirm that some events fall into a different day or month on the calendar because of the time zone of the observer. But I'm a bit tired now, probably will test tomorrow.

I don't plan to do any more on this stuff for now except for any fixes. Really it was some holiday work but has gone on 4 extra days and we all know what I really have to work on now.

I hope the calendar and league section improvements are helpful.
Scawen
Developer
I've now made the calendar default to a weekly view, in which only one week is shown and you can click back and forward through the weeks.

That's more useful when you want to find out what's on this week. You can also switch to monthly view as before.

https://www.lfs.net/leagues/calendar
Scawen
Developer
Thanks, the in-game entry screen only showed events whose first round was less than 36 hours ago. This allowed for 24 hour races and two-day events, but not three-day events.

I've increased that limit to 3 days instead of 36 hours, so the second part of your multi day round of one of your concurrent series now appears in the in-game calendar. Big grin


EDIT: Also added the option to delete a round. At the bottom of 'edit round' page (like deleting a season).
Last edited by Scawen, .
Scawen
Developer
One more question, on cleaning up the website...

Does anyone still use IRC?
I could remove the section from this page: https://www.lfs.net/links
FGED GREDG RDFGDR GSFDG