Author Topic: How to set up an automatic jump at a node  (Read 3851 times)

0 Members and 1 Guest are viewing this topic.

Offline HLD_Prophecy

  • PVD_Hope in a former life
  • 29
How to set up an automatic jump at a node
Hey all!

So I'd like to know how to set up an event so that the player automatically jumps when he reaches a certain node. The subspace drive is disabled otherwise.

I'm thinking "is-in-box", but doesn't that have to be tied to a subsystem? (Does a jump node have a subsystem? :P)

I mean, I suppose I could be un-lazy and make an AWOL debrief, but that would really mess up the immersion. And I'd still have to set it up so that the player could only "succeed" and continue to the next mission by jumping at the node.

This mod has a pretty unusual story, so plot and immersion reasons keep me from using many typical structures.

 

Offline General Battuta

  • Poe's Law In Action
  • 214
  • i wonder when my postcount will exceed my iq
Re: How to set up an automatic jump at a node
Do you want to allow the player to choose to jump, but only when inside the node?

Put a waypoint at the center of the node

When player is less than, uh, 100 meters (or whatever) from the waypoint, allow warp. Give this event 9999999 repeats with interval 0.

When player is greater than 99 meters (or whatever) from the waypoint, break warp. Give this event 9999999 repeats with interval 0.

 

Offline procdrone

  • Formerly TheHound
  • 29
  • Balance breaker! Thats me!
    • Steam
Re: How to set up an automatic jump at a node
in mission submenu, you also have "force-jump" sexp that forces player ship to jump and end the mission (regardless of subsystem status, it will force the jump whatever the conditions are). It cannot be disengaged afterwards.

so you can do it like:

when
player distance <=100 ; waypoint
   -force-jump
--Did it! It's RELEASED! VeniceMirror Thread--

 

Offline Mito [PL]

  • 210
  • Proud Member of Slavicus Mechanicus
Re: How to set up an automatic jump at a node
Or you just go with red-alert - if the campaign requires it.
How do you kill a hydra?

You starve it to death.

 

Offline HLD_Prophecy

  • PVD_Hope in a former life
  • 29
Re: How to set up an automatic jump at a node
Do you want to allow the player to choose to jump, but only when inside the node?

Put a waypoint at the center of the node

When player is less than, uh, 100 meters (or whatever) from the waypoint, allow warp. Give this event 9999999 repeats with interval 0.

When player is greater than 99 meters (or whatever) from the waypoint, break warp. Give this event 9999999 repeats with interval 0.

I'd like to do it this way. Thanks guys for your help!

Hey, crazy add-on question - is there any chance I could get the words "JUMP NOW" or something like that to fade in (as a subtitle, you know) whenever the player is in that <100 meters (or whatever) distance? And fade out if the player leaves it again?

 

Offline niffiwan

  • 211
  • Eluder Class
Re: How to set up an automatic jump at a node
show-subtitle-text or show-subtitle-image? Both seem to have fade in/out options. (disclaimer, I have not personally used these sexps!)
Creating a fs2_open.log | Red Alert Bug = Hex Edit | MediaVPs 2014: Bigger HUD gauges | 32bit libs for 64bit Ubuntu
----
Debian Packages (testing/unstable): Freespace2 | wxLauncher
----
m|m: I think I'm suffering from Stockholm syndrome. Bmpman is starting to make sense and it's actually written reasonably well...

 

Offline procdrone

  • Formerly TheHound
  • 29
  • Balance breaker! Thats me!
    • Steam
Re: How to set up an automatic jump at a node

I guess like this?

--Did it! It's RELEASED! VeniceMirror Thread--

 

Offline HLD_Prophecy

  • PVD_Hope in a former life
  • 29
Re: How to set up an automatic jump at a node
Whoa, thanks Hound! That's exactly what I wanted! Will set it up now.

 

Offline HLD_Prophecy

  • PVD_Hope in a former life
  • 29
Re: How to set up an automatic jump at a node
Um, how do you get the text to stay there until/unless you leave the node again? As I have it, the text just fades out like normal.

 

Offline procdrone

  • Formerly TheHound
  • 29
  • Balance breaker! Thats me!
    • Steam
Re: How to set up an automatic jump at a node
You could increase the timer on the text SEXP, but thats the not so good workaround.

I am not sure, the thing that I've shown in the video is exactly what you have on the screenshot. Im not sure how long it lasts... ill check later for that.
--Did it! It's RELEASED! VeniceMirror Thread--

 

Offline General Battuta

  • Poe's Law In Action
  • 214
  • i wonder when my postcount will exceed my iq
Re: How to set up an automatic jump at a node
Set the fadein time to 0 and the fadeout time to 1 second.

Make the event that puts the text on screen repeat every second. Have it fire only if the player is within jump range of the waypoint.

 

Offline procdrone

  • Formerly TheHound
  • 29
  • Balance breaker! Thats me!
    • Steam
Re: How to set up an automatic jump at a node
Set the fadein time to 0 and the fadeout time to 1 second.

Make the event that puts the text on screen repeat every second. Have it fire only if the player is within jump range of the waypoint.


That would be the way to do it I believe.
--Did it! It's RELEASED! VeniceMirror Thread--

 

Offline HLD_Prophecy

  • PVD_Hope in a former life
  • 29
Re: How to set up an automatic jump at a node
Set the fadein time to 0 and the fadeout time to 1 second.

Make the event that puts the text on screen repeat every second. Have it fire only if the player is within jump range of the waypoint.

So I can't have a fade in?

Sorry that I didn't respond for a while, I've been sick.

 

Offline HLD_Prophecy

  • PVD_Hope in a former life
  • 29
Re: How to set up an automatic jump at a node
I can't figure out how to get it to repeat every second. And the fadein time and the fadeout time are controlled by a single number; they have to be the same.

I'm sorry, I'm just confused.

 

Offline General Battuta

  • Poe's Law In Action
  • 214
  • i wonder when my postcount will exceed my iq
Re: How to set up an automatic jump at a node
Use the repeat count to the right of the event list in the events editor.

 

Offline HLD_Prophecy

  • PVD_Hope in a former life
  • 29
Re: How to set up an automatic jump at a node
Use the repeat count to the right of the event list in the events editor.

Okay thanks, I found it! Sorry for not looking harder.

And how do I put "once every second" in there? It's just a number - what does the number mean?

 

Offline AdmiralRalwood

  • 211
  • The Cthulhu programmer himself!
    • Skype
    • Steam
    • Twitter
Re: How to set up an automatic jump at a node
Repeat count and interval are separate boxes, and the latter is specified in seconds (with "0" meaning "every frame").
Ph'nglui mglw'nafh Codethulhu GitHub wgah'nagl fhtagn.

schrödinbug (noun) - a bug that manifests itself in running software after a programmer notices that the code should never have worked in the first place.

When you gaze long into BMPMAN, BMPMAN also gazes into you.

"I am one of the best FREDders on Earth" -General Battuta

<Aesaar> literary criticism is vladimir putin

<MageKing17> "There's probably a reason the code is the way it is" is a very dangerous line of thought. :P
<MageKing17> Because the "reason" often turns out to be "nobody noticed it was wrong".
(the very next day)
<MageKing17> this ****ing code did it to me again
<MageKing17> "That doesn't really make sense to me, but I'll assume it was being done for a reason."
<MageKing17> **** ME
<MageKing17> THE REASON IS PEOPLE ARE STUPID
<MageKing17> ESPECIALLY ME

<MageKing17> God damn, I do not understand how this is breaking.
<MageKing17> Everything points to "this should work fine", and yet it's clearly not working.
<MjnMixael> 2 hours later... "God damn, how did this ever work at all?!"
(...)
<MageKing17> so
<MageKing17> more than two hours
<MageKing17> but once again we have reached the inevitable conclusion
<MageKing17> How did this code ever work in the first place!?

<@The_E> Welcome to OpenGL, where standards compliance is optional, and error reporting inconsistent

<MageKing17> It was all working perfectly until I actually tried it on an actual mission.

<IronWorks> I am useful for FSO stuff again. This is a red-letter day!
* z64555 erases "Thursday" and rewrites it in red ink

<MageKing17> TIL the entire homing code is held up by shoestrings and duct tape, basically.

 

Offline HLD_Prophecy

  • PVD_Hope in a former life
  • 29
Re: How to set up an automatic jump at a node
Okay... so I have Trigger Count for the show subtitle text event set to 0 so that it will there will be no delay between tests of the event - is this right?

Really I'm confused as to the difference between Repeat Count, Trigger Count, and Interval Time. Can someone explain this to me?

Alos Interval Time is grayed out for this event, for some reason. Not sure why I can't edit it, it's locked at 1.


Not sure if it makes any difference, but my show subtitle text event is separate from the allow-warp event. The show subtitle text event is reliant on the allow-warp event being true.

 

Offline General Battuta

  • Poe's Law In Action
  • 214
  • i wonder when my postcount will exceed my iq
Re: How to set up an automatic jump at a node
No.

Trigger count says 'how many times can this event fire, assuming its conditions are true?'

Interval time says 'after the event fires, how long should I wait until I check to see if I can fire again?'

Just forget repeat count for now.

If your trigger count is set to zero the event will never happen. You need to set the interval count to zero to check every frame.

Never use trigger count with a chained event, afaik it gets weird.

 

Offline mjn.mixael

  • Cutscene Master
  • 212
  • Chopped liver
    • Steam
    • Twitter
Re: How to set up an automatic jump at a node
Never use trigger count with a chained event, afaik it gets weird.

All the big kids use Trigger Count, Repeat Count, and Chained Events for true chaos.  :nod:
Cutscene Upgrade Project - Mainhall Remakes - Between the Ashes
Youtube Channel - P3D Model Box
Between the Ashes is looking for committed testers, PM me for details.
Freespace Upgrade Project See what's happening.