Board index Roller Coaster Games NoLimits Coaster 2 Lost door trigger

Lost door trigger

All discussion relation to NoLimits Coaster 2 should be posted here. Purchase NoLimits Coaster from this page: nolimits-coaster-2-purchase-and-upgrade-links-t32524.html

Post April 9th, 2017, 12:56 pm

Posts: 69
Points on hand: 671.00 Points
Location: Kings Lynn, Norfolk, United Kingdom
Offline
Trying to get back into NL2 after a couple of years absence - I have a simple track (most of mine are as I experiment to relearn things) that has a simple 2-piece saloon type door that opens as the train approaches. However the realism is a bit of a fail as the door does not open quite in time and by now the train would have lost most of its front body work due to collisions.

My understanding of NL2 is that there is a trigger to open the door (and a trigger to close the door?) but I can't find it. Is it even there? I guess once I find it moving it would be simple. Bear in mind this is a simple gate, nothing fancy.

All help appreciated.

Post April 10th, 2017, 12:34 pm
herman116 User avatar
Premium Member
Premium Member

Posts: 636
Points on hand: 7,471.00 Points
Location: The Netherlands
Offline
It is possible to create a trigger in the coaster editor. However, it is also possible to create a trigger through scripting.

With the standard door script, the trigger is made by scripting. If you'll open the .nlvm file, you'll probably find something like this:

      // create a trigger 5 meters in front of the track pos
      beforeDoorTrigger = TrackTrigger.createTrackTriggerAtOffset(trackPos, -5.0);
     
      // create a trigger 5 meters after the track pos
      behindDoorTrigger = TrackTrigger.createTrackTriggerAtOffset(trackPos, +5.0);


This code will create the triggers. The door will open when it arrives at the first trigger and will close after it went past the second trigger. Which one is the first and which one is the second trigger will be determined by the orientation of the door.

When you want to open the door earlier, you should change the 5.0 in both lines to larger numbers like 10.0.

Sponsors
Did you know? Active community members enjoy an ad-free experience! Learn how ›
  • Rate 80%+ of your downloaded tracks (min 40 downloads)
  • Post at least 10 forum topics or replies in the last 90 days
  • Upload a track in the last 90 days
  • Earn 50,000+ points with a 10+ year account
  • Or become a Premium member

Return to NoLimits Coaster 2

 


  • Related topics
    Replies
    Views
    Last post