TimeTrial prefabs disappearing ?

Discussion in 'Content Creation' started by flykas, Jan 3, 2023.

  1. flykas

    flykas
    Expand Collapse

    Joined:
    Apr 2, 2016
    Messages:
    55
    I tried to do some time trials. All was successful until packing of prefabs. I placed a lot of object marking the boundaries of the track and stuff, packed it as a prefab and saved it in quickrace folder of a map "derby" also tried saving it in art/prefabs, but then I cannot find the prefab file and add it using race/path editor. I even did windows documents search and it does not find the file in whole computer. Only way to find it is to pack another prefab, then the previous file is visible in the save dialogue. Very frustrating. Can someone help? Thanks.
     
  2. flykas

    flykas
    Expand Collapse

    Joined:
    Apr 2, 2016
    Messages:
    55
    Ok, I have found out that I have to save the prefab and then manually add it to zip file of the level in the main game directory. But I have another question, can you somehow save the file in the middle of the process? Like if I started making a prefab fro time trial, but have to go away, I can't turn of the world editor because it will be lost? Or is there any way to save it and continue later?
     
  3. ltntai

    ltntai
    Expand Collapse

    Joined:
    Mar 18, 2017
    Messages:
    671
    Can you open the world editor while you are in a time trial? I can't anymore and see no way to load and edit old time trial prefabs.
    Is this a bug or was something changed on purpose? @Gamergull
    --- Post updated ---
    Update: Old prefabs can be edited only after completing a time trial and continuing in free roam.
    screenshot_2023-01-04_17-07-15.png screenshot_2023-01-04_17-08-18.png
     
    • Like Like x 3
  4. Gamergull

    Gamergull
    Expand Collapse
    BeamNG Team

    Joined:
    Jun 3, 2018
    Messages:
    460
    The World Editor input action got disabled for missions. However, losing the prefab file sounds like a bug...? I'll try to do the steps in the first post and see what happens.
     
  5. ltntai

    ltntai
    Expand Collapse

    Joined:
    Mar 18, 2017
    Messages:
    671
    Why? It was convenient to start a time trial and be able to edit the path and the prefab at once.

    I noticed there's no need to pass the trial to edit the prefab. But it's still extra steps compared to the old way: Spawn prefab at origin in Asset Browser.
    screenshot_2023-01-05_22-38-10.png screenshot_2023-01-05_22-38-50.png screenshot_2023-01-05_22-39-16.png
     
  6. flykas

    flykas
    Expand Collapse

    Joined:
    Apr 2, 2016
    Messages:
    55
    Now I can find the file. Maybe it did not save for the first time. However, for me the prefab only works in missions. When I start the time trial from the time trial game mode, it works, but without the prefab objects.
     
  7. Gamergull

    Gamergull
    Expand Collapse
    BeamNG Team

    Joined:
    Jun 3, 2018
    Messages:
    460
    I suppose it was done to prevent cheating. However, I actually agree that it was helpful for editing a mission. Might inquire about this.

    I'll investigate. I do know that the old time trial mode is less supported now, but the prefab processing should still be compatible.
     
    • Like Like x 1
  8. Gamergull

    Gamergull
    Expand Collapse
    BeamNG Team

    Joined:
    Jun 3, 2018
    Messages:
    460
    Supposedly, the main prefab should load automatically if it is in the same folder, and has the same name as the race path file (minus the extensions). But I ran into some trouble with this myself. Manually editing in the prefab file path in the race path file worked for me:
    quickrace-prefab.jpg

    Maybe this is a thing that can be done from the Race/Path Editor. I hope this helps; I'm only partly knowing about the quickrace subsystem.
     
  9. flykas

    flykas
    Expand Collapse

    Joined:
    Apr 2, 2016
    Messages:
    55
    Now the problem is that prefab doesn't load in time trial mode. Its just time trial without prefab objects. However prefab works when starting as a mission in freeroam, but how can I edit it? I can't turn on the editor during a mission and after the mission the prefab is not there. I see it in the scene tree as a packed prefab, but how can I make it appear in the level?
     
  10. ltntai

    ltntai
    Expand Collapse

    Joined:
    Mar 18, 2017
    Messages:
    671
    I made a new time trial for Derby Arenas using the race/path editor and saved the files to quickrace folder. Prefab works in both game modes on my end. Put the .zip in your mods folder and try to unpack, edit, and repack the prefab. When you repack, the game creates a new .prefab to 0.27/levels/derby/quickrace/. Don't save the level before exiting.
     

    Attached Files:

  11. KillerBee 2

    KillerBee 2
    Expand Collapse

    Joined:
    May 21, 2021
    Messages:
    84
    I came here looking for the same answer. What I noticed is the prefab is still there in physics wise but visually it's not. I added some spike strips into an ai race and noticed they were gone when I went back to the map but when a car passed over it the tires popped. This has to be a bug.
    --- Post updated ---
    I think I figured it out. You have to move pack into a mod, Apparently, leaving it in the temp folder does not load everything. This video shows how at the end. Basically, you move the game[lay that you want to the unpacked folder in mods and delete the one in the temp gameplay folder, It worked for me,

     
    • Like Like x 1
  12. flykas

    flykas
    Expand Collapse

    Joined:
    Apr 2, 2016
    Messages:
    55
    Ok, when I put your zip file into mods it works and prefab objects show up in quickrace and freeroam mission. But I don’t know how to unpack that prefab, it is not in the scene tree. Also I tride to pack my trial the same as yours and put it into mods folder, but then it does not show up at all. Then I put all the files of my trial into quickrace folder and it works but prefab objects only show up in mission but not in time trial mode. So complicated…
    --- Post updated ---
    Tried this, but when I pack the trial through mod manager it just doesn’t show up in game.
     
  13. flykas

    flykas
    Expand Collapse

    Joined:
    Apr 2, 2016
    Messages:
    55
    Okay, I must have somehow messed up the prefab on the derby map, because I just created new time trial on a different map, everything works fine. Prefabs work, I can edit them. Just will have to learn to pack it properly for sharing. Thanks for your help.
     
    • Like Like x 1
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice