Build 982 Knockout Qualifying

Discussion in 'General Discussion' started by Lazza, Jul 1, 2015.

  1. MarcG

    MarcG Registered

    Joined:
    Oct 4, 2010
    Messages:
    6,854
    Likes Received:
    2,234
    Right I've got 25 cars in Qual Session 1, with the "TimedLapRequired":1, they all go and do one flying lap, come in then go back out for more laps. I then have Session 2 working fine with the Top Ten who all then go out at once and do as many laps as they can, thus ignoring the "TimedLapRequired":1,.

    The main thing is getting AI to go out 1 by 1 in the second session which I firmly believe won't be possible, that's not a huge deal but getting them to do just one lap in that second session may be a pitfall!
     
  2. MarcG

    MarcG Registered

    Joined:
    Oct 4, 2010
    Messages:
    6,854
    Likes Received:
    2,234
    ok ignore the "TimedLapRequired":1, it doesn't appear to be doing anything for me. I can get two sessions with a Top Ten in the second but no matter what I do they go out for more than one lap.

    Here's what I think needs to be done, we need to be able to limit the Laps as well as the Time (this doesn't work, just an example):

    "Total2Session1Minutes":25,
    "TimedLapRequired":0, // 0 = infinity, 1 = 1 Timed Lap, 2 = 2 Timed laps etc
    "Total2Session1Scored":25,
    "Total2Session2Minutes":30,
    "TimedLapRequired":1,
    "Total2Session2Scored":10,

    ( Of course if anyone can get Timed laps to work like how I want then please do shout :) )

    Online it would be simple enough to have each car go out 1 by 1 in the Top Ten, so again getting the AI to do it would probably have to be hard coded into the plug in somehow...wouldn't have a clue myself!
     
  3. Lazza

    Lazza Registered

    Joined:
    Oct 5, 2010
    Messages:
    12,382
    Likes Received:
    6,600
    TimedLapRequired means a driver has to set a time in order to move to the next session. The maximum number of laps in the session would be set in the normal way.

    With TimedLapRequired = 1, if only 5 drivers set a time, then only those drivers can drive in the next knockout session even if you've said 10 should take part. Hope that makes sense.
     
  4. MarcG

    MarcG Registered

    Joined:
    Oct 4, 2010
    Messages:
    6,854
    Likes Received:
    2,234
    aahh I see yeah thanks, so you can't set Number of Laps per Session then? can't find anything in the player.JSON pretty sure there used to be something like that :confused:
     
  5. Lazza

    Lazza Registered

    Joined:
    Oct 5, 2010
    Messages:
    12,382
    Likes Received:
    6,600
    One thing I should mention: plugins are able to set the maximum number of laps allowed in the current session (for qual sessions), however this KnockoutQualifying plugin doesn't appear to offer that option.
     
  6. Lazza

    Lazza Registered

    Joined:
    Oct 5, 2010
    Messages:
    12,382
    Likes Received:
    6,600
    Yeah, just a single setting: Game Options: qualifying laps. So with this plugin not letting you alter that per Q session, you'd be limited to either a single lap in every qual session (yuck!) or just accept that AI will do more than one lap in a 'top 10' session.
     
  7. MarcG

    MarcG Registered

    Joined:
    Oct 4, 2010
    Messages:
    6,854
    Likes Received:
    2,234
    Yeah ok cool thanks and good to know it doesn't work...if that makes sense!

    Would be great to have this made possible for a future update to the plug in, so at least it'd be "simple" to edit in the CustomPluginVariables.JSON:

    "Total2Session1Minutes":25,
    "Hot Laps Allowed":0, // 0 = infinity, 1 = 1 Hot Lap Lap, 2 = 2 Hot laps etc
    "Total2Session1Scored":25,
    "Total2Session2Minutes":60,
    "Hot Laps Allowed":1,
    "Delay AI": 200, // Time in Seconds to Delay each individual AI (1 by 1)
    "Total2Session2Scored":10,

    I just threw that one in there for giggles :p
     
  8. Lazza

    Lazza Registered

    Joined:
    Oct 5, 2010
    Messages:
    12,382
    Likes Received:
    6,600
    lol

    Well a long time ago I said I'd get a plugin going to handle various qualifying scenarios, and due to various things it hasn't yet got past planning stage. I have to admit I hadn't considered top 10 shootouts (or similar) but when I get something happening I'll be sure to test options in that direction :)
     
  9. GCCRacer

    GCCRacer Banned

    Joined:
    Dec 12, 2012
    Messages:
    1,317
    Likes Received:
    2
    Thanks a lot, I got it now.

    So basically the magic trick is NOT to reduce the block of text to just the sessions you want. Since everyone had been pasting code snippets of six lines for three sessions, that's what I did. But instead it needs all lines to be present and ignores those that don't apply.

    Still think this needs to go into rFM, since changing between a 1992 season and a 2013 season now requires an edit in a text file. Normally I just have two different rFMs for these two seasons.

    As for documentation - in my perfect world complicated stuff like this would have a comment link in the textfile (rf2wiki.org/pageid=whatever) and on that wiki all stuff would be detailed explained.
     
  10. MarcG

    MarcG Registered

    Joined:
    Oct 4, 2010
    Messages:
    6,854
    Likes Received:
    2,234

    yes the whole code.
    Just have different CustomPluginVariables.JSON files relevant to whichever series, saves faffing about repackaging RFM mods to uninstall/re-install every time etc. (unless thats changed!)

    Edit: above easier for offline use that is

    Of course the simplest way would be to have all this Qualifying Rules IN GAME ;)
     
    Last edited by a moderator: Sep 19, 2015
  11. Lazza

    Lazza Registered

    Joined:
    Oct 5, 2010
    Messages:
    12,382
    Likes Received:
    6,600
    Yeah, that does make some sense too. You'd still want the freedom to override it (a league might want to do knockout with a 92 mod... or not do knockout with a 2013 mod). If you have your 3 sessions set up right, and your 1 session set up right, it's just the single change you need to make (NumQualSessions).

    The plugin solution to this is being able to set the parameters per mod (class) if desired.
     
  12. GCCRacer

    GCCRacer Banned

    Joined:
    Dec 12, 2012
    Messages:
    1,317
    Likes Received:
    2
    Yeah okay if this could be clasd specific it would also work...
     
  13. GCCRacer

    GCCRacer Banned

    Joined:
    Dec 12, 2012
    Messages:
    1,317
    Likes Received:
    2
    BTW Lazza, you're kind of the expert here :)

    Could the Rules Plugin be used to hack a "save grid for racing later" functionality?

    Because right now, offline you have to run Q and R next to each other. If you set a manual grid position in the GUI, the entire other field is totally randomized (faster drivers regularly at the back). So it's very time consuming to have a proper offline race.

    By simulating a "short" one-minute Q session and loading the results from the last Q log, maybe it would be possible to split the two?
     
  14. Lazza

    Lazza Registered

    Joined:
    Oct 5, 2010
    Messages:
    12,382
    Likes Received:
    6,600
    That's something I would definitely support when I get to doing a plugin, but something I suggested in another thread (but haven't tested) is whether you can start the Race session, let it run for a couple of mins, then quit... but have the replay saved. Then you can come back later, play the replay long enough to rescue the realroad you had (it tends to come back in patches with replays), then resume. Not even sure if it works that way, but worth a shot.
     
  15. GCCRacer

    GCCRacer Banned

    Joined:
    Dec 12, 2012
    Messages:
    1,317
    Likes Received:
    2
    Yes, I'm fairly sure a race resume from replay would work. Yet replay introduces weird stuff into my cars (for example permanent flashing rear lights on 2013 Mod). And since you can't button-press enable and disable replay you'd be recording a lot of replays just to get a "savepoint", whereas the Log file is automatically generated after the Q sessions. And Realroad is auto-saved on quit too.

    In fact I'm somehow surprised ISI never enabled such a feature. Both the road data and grid data are already stored in a complete and easy to read file - there's no magic in loading it I would assume. I'm not even sure the game - between P,Q,R - doesn't use the log files and real road saves itself already to "progress".
     
  16. Enetmo

    Enetmo Registered

    Joined:
    Dec 18, 2011
    Messages:
    153
    Likes Received:
    1
    Hi all guys!!
    Can you add a command line to the plugin to indicate "Parc Ferme" conditions in a qualifying session and also carry those "Parc Ferme" conditions from one session to the next? Can you change "the parc ferme" conditions in any given session. For example, I would like to be able to change setup in the 2 first sessions and then the 3rd session to be "parc ferme".
    How could I do that?

    See attached file for example:

    View attachment 18959
     

Share This Page