Author Topic: Allow-warp not working  (Read 1318 times)

0 Members and 1 Guest are viewing this topic.

Allow-warp not working
Ok so I have this mission. The Subspace drive is deactivated because of some cool in-mission-jumping  ;7

After the win condition is triggered (escorts saved and they jumped to safety), I used the "allow-jump" sexp to, well, allow the player ship to jump again, so that the player can jump out at the end anytime he wants. But it doesn't seem to be working since nothing happens when I press ALT-J after that...

Any suggestions? Could it have something to do with the used "key pressed" and "key reset" sexps for the in mission jump?

I could force the player to jump after the Win Condition event has become true, this is working. But the other way would feel "smoother"...

Thanks for help!

  

Offline AdmiralRalwood

  • 211
  • The Cthulhu programmer himself!
    • Skype
    • Steam
    • Twitter
Re: Allow-warp not working
Any suggestions? Could it have something to do with the used "key pressed" and "key reset" sexps for the in mission jump?
Depends on how you implemented those events; your best bet is probably to pastebin the .fs2 file so someone can see if there's a logic error in your SEXPing.
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 Axem

  • 211
Re: Allow-warp not working
If you're using in mission jumps, I'm guessing you had some method to stop the player from actually engaging the real jump drive. How did you do that? Did you use never-warp or did you disable the player's subspace drive (maybe through the ship flag editor)? If the latter, you'll need to re-enable it through the alter-ship-flag sexp.

 
Re: Allow-warp not working
@ AdmiralRalwood: I think there's no need to pastebin the file, since Axem might have found the solution. But thanks, anyway!

@ Axem: I'm using your In-Mission-jump-tutorial. It's pretty awesome, by the way  :D

Ok, I thought that allow-warp would automatically alter the "No subspace drive" flag in the flag editor. So allow-warp is just the opposite of never-warp and has nothing to do with the set ship flag? I think that's the solution.

I'll try this afternoon and give you feedback, thanks!
« Last Edit: January 10, 2018, 07:15:23 am by bomb3rman »

 
Re: Allow-warp not working
So allow-warp is just the opposite of never-warp and has nothing to do with the set ship flag?
They have similar effects, but they are separate. Never-warp gives you a system error message ("Engine failure! Can't jump!" or w/e) if you Alt-J while 'No Subspace Drive' does nothing at all when you try, a very important and useful difference!

 
Re: Allow-warp not working
OK now I get it, thanks.

It's working, by the way :)