Elevator won't move

Avatar
Dafflewoctor
415 Posts
Posted Sep 05, 2013
So after editing the elevator to put in a scene where the elevator breaks down, I think I broke something having to to with the elevator track train moving, because apparently they used a script code: StartMoving() or something like that. But for some reason it won't move when step in. I have only deleted several path_tracks near the top where I don't want the elevator to move and took out the transition script codes that come from the path_tracks because it isn't the end of the map yet.

I also have a very strong feeling I'll need to post the .vmf, so just say the word.

Also: Where does the elevator moving sound come from? A hidden ambient_generic or is it part of a script?

Advertisement
Registered users don’t see ads! Register now!
Avatar
FelixGriffin
2,680 Posts
Posted Sep 05, 2013
Replied 27 minutes later
I can only answer the second part now: I believe it comes from the tracktrain entity.
Avatar
josepezdj
2,386 Posts
Posted Sep 06, 2013
Replied 9 hours later

Dr.Toaster Waffles wrote:
I also have a very strong feeling I'll need to post the .vmf, so just say the word.

"The word" :lol:

I'd like to know if it's the arrival or it's the departure elevator that you're editing... and "how much" did you edit it... If you mention that you deleted some path_tracks, maybe your func_tracktrain doesn't move because you didn't specify a 'First Stop Target' in their properties.

Dr.Toaster Waffles wrote:
Also: Where does the elevator moving sound come from? A hidden ambient_generic or is it part of a script?

No, sounds are just set up into the func_tracktrain properties: 'Start Sound', 'Stop Sound', 'Move Sound'... :wink: (same as the func_doors, func_movelinears, etc.)

Quick Tips:

  1. Check the console for problems... If you don't see any problem, then enter in the command: developer 2 and you will see a bunch of internal messages that tells you what the engine is doing and maybe any error message that wouldn't appear normally (turn that off again with developer 0)

  2. For the invisble brush entities (those that you texture in nodraw, trigger or invisible toolstextures for example), you can texture them for amoment with a visible texture (for example a white wall texture) and compile to see if and how they work (i.e. if the tracktrain moves or not)

:wink:

Avatar
Dafflewoctor
415 Posts
Posted Sep 06, 2013
Replied 3 hours later

josepezdj wrote:
Dr.Toaster Waffles wrote:

I also have a very strong feeling I'll need to post the .vmf, so just say the word.

"The word" :lol:

I'd like to know if it's the arrival or it's the departure elevator that you're editing... and "how much" did you edit it... If you mention that you deleted some path_tracks, maybe your func_tracktrain doesn't move because you didn't specify a 'First Stop Target' in their properties.

Dr.Toaster Waffles wrote:

Also: Where does the elevator moving sound come from? A hidden ambient_generic or is it part of a script?

No, sounds are just set up into the func_tracktrain properties: 'Start Sound', 'Stop Sound', 'Move Sound'... :wink: (same as the func_doors, func_movelinears, etc.)

Quick Tips:

  1. Check the console for problems... If you don't see any problem, then enter in the command: developer 2 and you will see a bunch of internal messages that tells you what the engine is doing and maybe any error message that wouldn't appear normally (turn that off again with developer 0)

  2. For the invisble brush entities (those that you texture in nodraw, trigger or invisible toolstextures for example), you can texture them for amoment with a visible texture (for example a white wall texture) and compile to see if and how they work (i.e. if the tracktrain moves or not)

:wink:

Thanks both of you, I always wondered if there was a way to see all your map's internal workings in the console. Also for invisible brush entities, that question was actually for a different map, I'm sort of working on two at once. :lol: Thanks anyways though!

For your other question it is the departure elevator I'm working on. I'm not editing them like you and FourthReaper do for your maps, I'm just trying to get the elevator to break down and then go haywire. I do have a first stop target specified and I only deleted some path_tracks near the top because I don't want to let the elevator go that far.

Please note this isn't the whole map, it's just the edited elevator I'll put in the map. It's also not done yet and there are several other bugs I know how to fix. Basically: whoever downloads it, don't play it because it doesn't work.

Avatar
josepezdj
2,386 Posts
Posted Sep 06, 2013
Replied 21 minutes later
K, downloaded. Let me arrrive home and take a look.

Dr.Toaster Waffles wrote:
I do have a first stop target specified and I only deleted some path_tracks near the top because I don't want to let the elevator go that far.

Question: can you see thin lines connecting the path_tracks that you kept in? maybe the first stop target is set but not the rest of the system.....

I'll post whatever I find :wink:

EDIT

OK, just did what I told you to do: I enabled the developer messages and found this:

(7.05) output: (trigger_multiple,) -> (not_colliding_with_elevator,SetValue)(0)
(7.07) input : not_colliding_with_elevator.SetValue(0)
(7.07) input not_colliding_with_elevator: logic_branch_listener._OnLogicBranchChanged()
(7.17) output: (trigger_multiple,) -> (in_elevator,SetValue)(1)
(7.17) input : in_elevator.SetValue(1)
(7.17) input in_elevator: logic_branch_listener._OnLogicBranchChanged()
(7.33) output: (trigger_multiple,) -> (not_colliding_with_elevator,SetValue)(1)
(7.33) input : not_colliding_with_elevator.SetValue(1)
(7.33) input not_colliding_with_elevator: logic_branch_listener._OnLogicBranchChanged()
(7.33) output: (logic_branch_listener,) -> (close,Trigger)()
Removing from action list: (logic_branch_listener,) -> (close,Trigger)
(7.33) output: (logic_branch_listener,) -> (@glados,RunScriptCode)(ExitStarted())
Removing from action list: (logic_branch_listener,) -> (@glados,RunScriptCode)
(7.33) output: (logic_branch_listener,) -> (elevator_doorclose_playerclip,Enable)()
Removing from action list: (logic_branch_listener,) -> (elevator_doorclose_playerclip,Enable)
(7.33) output: (logic_branch_listener,) -> (signs_off,Trigger,1.0)()
Removing from action list: (logic_branch_listener,) -> (signs_off,Trigger)
(7.33) output: (logic_branch_listener,) -> (elevator_1,StartForward,1.0)()
Removing from action list: (logic_branch_listener,) -> (elevator_1,StartForward)
(7.33) output: (logic_branch_listener,) -> (floor_clip,Disable,1.0)()
Removing from action list: (logic_branch_listener,) -> (floor_clip,Disable)
(7.33) input : close.Trigger()
(7.33) output: (logic_relay,close) -> (elevator_tube_opener,SetAnimation)(close)
(7.33) output: (logic_relay,close) -> (elevator_tube_opener,SetDefaultAnimation,0.1)(close_idle)
(7.33) output: (logic_relay,close) -> (elevator_1_body,SetDefaultAnimation,0.1)(doorclose_idle)
(7.33) output: (logic_relay,close) -> (elevator_1_body,SetAnimation)(doorclose)
unhandled input: (RunScriptCode) -> (@glados), from (logic_branch_listener,); target entity not found
(7.33) input : elevator_doorclose_playerclip.Enable()
(7.33) input close: elevator_tube_opener.SetAnimation(close)
(7.33) input close: elevator_1_body.SetAnimation(doorclose)
(7.43) input close: elevator_tube_opener.SetDefaultAnimation(close_idle)
(7.43) input close: elevator_1_body.SetDefaultAnimation(doorclose_idle)
(7.47) input close: close.EnableRefire()
(8.33) input : signs_off.Trigger()
(8.33) output: (logic_relay,signs_off) -> (video_script,RunScriptCode)(StopDepartureVideo(23,2))
(8.33) input : elevator_1.StartForward()
TRAIN(elevator_1): Dead end at elevator_1_path_0
(8.33) input elevator_1: elevator_1_path_0.InPass()
TRAIN(elevator_1), speed to 0.00
(8.33) input : floor_clip.Disable()
(8.33) input signs_off: video_script.RunScriptCode(StopDepartureVideo(23,2))
(8.33) input video_script: @departure_video_master.Disable()
(

The key message is: TRAIN(elevator_1): Dead end at elevator_1_path_0

So I went to your path_track called elevator_1_path_0, and this is what I found:

img
It had a missing "Next stop target" (one of those that you erased :wink:) What I did was to put there the name of your latest one, elevator_1_path_11, now it works...

Btw, was it intended to set the max. elevator (func_tracktrain) speed to 1000? >.< I've changed it to 300... lol the player got catapulted!

Map attached (.BSP and .VMF)

OK, I don't know what kind of elevator break are you trying to develop, so I'll stop here.

Good luck! :thumbup:

Attachments
Toaster.7z
0.25 MB 45 downloads
Avatar
Dafflewoctor
415 Posts
Posted Sep 07, 2013
Replied 1 day later
Thanks again! One more question: I want to change the speed of the elevator train at one point to make it go faster, but using SetSpeed, SetSpeedReal, or SetSpeedDir don't work, I don't notice any difference. (I don't want to just write 500 in the properties because I want it to stay at 300 for a while.)
Avatar
josepezdj
2,386 Posts
Posted Sep 07, 2013
Replied 4 hours later

Dr.Toaster Waffles wrote:
One more question: I want to change the speed of the elevator train at one point to make it go faster, but using SetSpeed, SetSpeedReal, or SetSpeedDir don't work, I don't notice any difference. (I don't want to just write 500 in the properties because I want it to stay at 300 for a while.)

You need to do it in a different way. If for exampl you want your train to change from an initial speed of 300 to a 100 when it passes on a given path_track, just add the following output in the path_track from which you need your train to change its speed:

- My outpout named: OnPass
- Targets entities named: [train_name_here]
- Via this input: AddOoutput
- With a parameter override of: speed 100
- After a delay in seconds of: [whatever]

Avatar
Dafflewoctor
415 Posts
Posted Sep 07, 2013
Replied 52 minutes later
That doesn't seem to be working...it's not that big of a problem though, it doesn't have to go faster.

Also I hate to ask more questions but during the breakdown it starts traveling reverse and goes back through the elevator room tube. Sometimes when I'm inside the elevator and I stand very close to the door I get caught and somehow merge myself into the elevator model is what it looks like. A developer 2 error writes that the train is being blocked by the player. It doesn't happen all the time but frequently enough. There aren't any clips that I can see in the map...

Avatar
josepezdj
2,386 Posts
Posted Sep 07, 2013
Replied 1 hour later
That DOES work. A working example is attached.

Dr.Toaster Waffles wrote:
Also I hate to ask more questions but during the breakdown it starts traveling reverse and goes back through the elevator room tube.

No, it doesn't start backwards, after passing your uppermost path_track (number 11) it goes to another path_track that you placed at the bottom called "elevator_1_path_fall_01" because it is the "Next Stop Target" you have set up in the path_track called "elevator_1_path_11"... just give it no next stop target and it'll simply stop.

I can't reproduce the other issue of blocking the train.

Attachments
train_test.7z
0.02 MB 40 downloads
Avatar
Dafflewoctor
415 Posts
Posted Sep 07, 2013
Replied 1 hour later
Thanks, but let me rephrase that: It is supposed to go reverse through the elevator tube, that's why I have the path_track. The only problem is the player-tube-blocky-thing, and hopefully this example will show me what I did wrong with the speed. :razz: Thanks for helping so far though

EDIT: Now this is really strange...when I turn on developer 2 and pass the path_track that changes the speed, it writes that the train's speed has been set to -300 when I have 550 as the speed change. And the speed doesn't actually change at all, just keeps going at 300.

The path_track second to top is that changes the speed. You should also be able to replicate my error in the file attached, just wait for Wheatley's dialogue to finish and as it comes down look straight ahead and stand right behind the door.

Avatar
josepezdj
2,386 Posts
Posted Sep 07, 2013
Replied 10 minutes later
Man, I don't know the complete scene you are creating, so it's difficult to be of more help :biggrin:

If you actually need it to go backwards, just use the output StartBackwards although remember that you need to set a non-zero value for the property "New train speed" into EACH of the path_tracks involved in the train's movement for this output to work. I've used many times this output and works out great :wink:

Avatar
Dafflewoctor
415 Posts
Posted Sep 07, 2013
Replied 23 minutes later
That would be a good idea but I need the train to be going normal speed until it stops, then when it starts coming down go faster, so if I used the new train speed it will make it fast both times...

Also I was editing my post while you were creating one :lol: , I attached the updated file in my previous post so you can play it and see the sort of thing I'm trying to do.

Avatar
josepezdj
2,386 Posts
Posted Sep 09, 2013
Replied 1 day later

Dr.Toaster Waffles wrote:
EDIT: Now this is really strange...when I turn on developer 2 and pass the path_track that changes the speed, it writes that the train's speed has been set to -300 when I have 550 as the speed change. And the speed doesn't actually change at all, just keeps going at 300.

Hmmm... about this I know why it didn't work. You set this change of speed into the path track no. 10... but if you remember, when I edit your system after the first problem (elevator didn't move at all) I set as "Next Stop target" in the bottom path_track the topmost one called number 11, therefore your train didn't pass through path no. 10 :biggrin:

Try setting as "Next Stop Target" the following path to your bottom one :wink: (I think the bottom was no. 0, so set as next the no. 1). This way I think your train will pass through all of them to the top; if you set the "AddOuput" output into the last-top path_track after the train has stopped, then when you give it the order to go backwards, it should do it to the new speed, 550. Try it...

Avatar
FelixGriffin
2,680 Posts
Posted Sep 09, 2013
Replied 2 hours later
One trick with what you're doing: an object in free-fall has roughly constant acceleration, but the best you can do with a func_tracktrain is roughly constant velocity. Try using a phys_convert on the elevator model (or whatever brush the player is colliding with, it'll work on any entity) at the top and watch it fall with perfect physics. :smile:
Avatar
Dafflewoctor
415 Posts
Posted Sep 11, 2013
Replied 1 day later

josepezdj wrote:
Dr.Toaster Waffles wrote:

EDIT: Now this is really strange...when I turn on developer 2 and pass the path_track that changes the speed, it writes that the train's speed has been set to -300 when I have 550 as the speed change. And the speed doesn't actually change at all, just keeps going at 300.

Hmmm... about this I know why it didn't work. You set this change of speed into the path track no. 10... but if you remember, when I edit your system after the first problem (elevator didn't move at all) I set as "Next Stop target" in the bottom path_track the topmost one called number 11, therefore your train didn't pass through path no. 10 :biggrin:

Try setting as "Next Stop Target" the following path to your bottom one :wink: (I think the bottom was no. 0, so set as next the no. 1). This way I think your train will pass through all of them to the top; if you set the "AddOuput" output into the last-top path_track after the train has stopped, then when you give it the order to go backwards, it should do it to the new speed, 550. Try it...

Thank you! I never checked my path_tracks. I'll try this later today.

@FelixGriffin: I would do that, but I'm not exactly trying to give it the effect that it's falling, more so that something went wrong with the elevator and now it's traveling at a dangerously high speed. But thank you still!

Avatar
Dafflewoctor
415 Posts
Posted Sep 11, 2013
Replied 12 hours later
Alright, well, thanks! Works fine now. Another problem was that the maximum speed of the train was set to 300, so I had to change that too.

But the bug is still occuring, and it's really starting to get on my nerves.

Avatar
josepezdj
2,386 Posts
Posted Sep 12, 2013
Replied 6 hours later
That output I told you to use (AddOuput > speed 550) was for changing the max speed keyvalue of your func_tracktrain... I insist in what I told you in steam: get rid of the scripts and control the whole system yourself :wink:

If that left bug is that the player can almost get out of the elevator when it is falling or going backwards, why don't you parent a disabled func_brush textured with playerclip to it, and you enable it when the elevator starts backwards? There's already one at the bottom part of the elevator shaft shaped like the elevator.

Avatar
Dafflewoctor
415 Posts
Posted Sep 13, 2013
Replied 1 day later
But the player would get stuck in the player clip if they were standing in it while it was being enabled...
Avatar
HMW
806 Posts
Posted Sep 14, 2013
Replied 15 hours later

With regard to the clipping problem, I think all you need to do is to parent the "elevator_doorclose_playerclip" entity to the "elevator_1" func_tracktrain. (The names are from "departure_elevator_a4_logic.vmf" but they are probably the same everywhere.) That way, the barrier moves with the player so they can't get stuck in it. Remember to disable it again when you want the player to get out.

elevator parts.png
Advertisement
Registered users don’t see ads! Register now!
Avatar
Dafflewoctor
415 Posts
Posted Sep 14, 2013
Replied 1 hour later

HMW wrote:
With regard to the clipping problem, I think all you need to do is to parent the "elevator_doorclose_playerclip" entity to the "elevator_1" func_tracktrain. (The names are from "departure_elevator_a4_logic.vmf" but they are probably the same everywhere.) That way, the barrier moves with the player so they can't get stuck in it. Remember to disable it again when you want the player to get out.

:potd: :potd: :potd: :potd: :potd: :potd:

I can't express my gratitude. Thank you very much!