Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Sergeant_Mark_IV

A level onboard a vehicle, is that possible?

Recommended Posts

Okay, I want to know if I can make a level onboard a vehicle, such a car, or a train. You don't need to control it. You just need to stay alive until you reach the end of the road.


I saw something like that in Zblud, but actualy, the train dont moves, the terrain texture does moves, giving the felling that the train is moving. What I want is to make the train to move, and over a determinated course. Is that possible?

PS: Using GZDoom format.

Share this post


Link to post

Going from what gggmork said in this thread, it'd be theoretically possible to make a flatbed car type of thing for a train that's 1 unit tall float over a rail with thrust. Figuring out how to make that thing convincing (possibly multi-sprite objects, or moving models instead?) is a problem though.

Share this post


Link to post

You can't have horizontally moving sectors in GZDoom. The closest thing to them are PolyObjects, but those are infinitely tall.

If you don't like the moving textures approach, you could use a moving SkyPicker.

You could make something similar to Action Doom's boat ride.

Share this post


Link to post

One example on how to do this: make a train inside a tunnel. The tunnel textures move, making it appear that your train is moving. A stretch of one of the tunnel walls is made up of two polyobjects which, after a predetermined time period, slide open revealing a gap where a station would fit, both parts move along the track preserving the new gap, making it appear as if the train arrives at a station.

A better way would be to use a skybox with a moving camera going past the scenery you want to see from the train. But, a player moving at a right angle to the driving direction doesn't get adjusted so your scenery appears to be moving from side to side as well. A solution to that would be a script that moves your camera in accordance to the player's side-to-side motion, but I'm not sure if that is possible.

Share this post


Link to post
Sergeant_Mark_IV said:

What I want is to make the train to move, and over a determinated course. Is that possible?

No.

Well, you could make a train model move. But objects don't have friction, so a player could not be onboard the train.

So if you want the player to be aboard a train that moves, you have to fake the movement and get a train that's actually not moving.

Or you have to use another engine. Even with scripting tacked on, Doom was never designed to be a railway simulator.

Share this post


Link to post

It is impossible, in the sense that it is impossible to 'map' vehicles, also it would be in your best interest to make whatever your playing area is stationary and make everything that you aren't supposed to make contact with in motion.

There are many ways to give the illusion you are on a moving vehicle. in fact the megawad TVR (I think that's what it was called) had a vanilla way to do it using a single scrolling texture to make it appear as though you were on a moving train.

In Boom there are scrolling floors and conveyor-belts and such to further stimulate this effect.

Share this post


Link to post

Technically speaking, having the environment moving but the vehicle stationary is just a relative experience. In game it's convincing enough.

Share this post


Link to post

I know about this way, but the bad thing on it is the fact that you can't make a completely moving scenario, with trees, rocks, etc. Also, If you want to make the train stop, you must finish the level, and start a new one with the train already stoped.

Share this post


Link to post
Sergeant_Mark_IV said:

I know about this way, but the bad thing on it is the fact that you can't make a completely moving scenario, with trees, rocks, etc.

Yes you can.
http://www.doomworld.com/idgames/index.php?id=11111

LWM did some cunning scripted sprite based sand dunes in her boat ride in Chosen.
http://www.doomworld.com/idgames/index.php?id=12363

Sergeant_Mark_IV said:

Also, If you want to make the train stop, you must finish the level, and start a new one with the train already stoped.

True, but you can teleport the player around the map fairly seamlessly so there is no need for a new map a lot of the time.

Bottom line, what you want to do can't be done in the Doom engine so you will either have to resort to the kind of tricks that you don't want to use, or pick a different engine.

Share this post


Link to post
Gez said:

So if you want the player to be aboard a train that moves, you have to fake the movement and get a train that's actually not moving.


I didn't try it yet, but what about using thrust_thing a tiny bit on a caco (or train made of cacos etc) every frame. Also record the cacos x,y,z bounding box coordinates every frame (assuming possible). Then have a condition where only if the player is standing right on top of the caco, the player is thrusted too in the same direction as a the caco. (maybe using thing stop before each thrust too on the caco and player to prevent any vector from causing the player to slide off like ice hockey).

edit: now that I think about it, the player probably couldn't walk around normally on a caco because they'd be 'in air'. I guess you couldn't jump while in air on a caco either. Unless more coding could fix those problems.

not sure how the below would work but interesting idea (I interpreted the x/o pic as top view with doomguy in center) because I don't think things have weight and probably can't push other things (so if a thing is thrusted into doomguy, it might just stop rather than push him).

Share this post


Link to post

A small idea to add to gggmork's ideas - if it's a small mining car or moving platform made out of things, you could use one thing for the center of the platform, then put things around it that are at least 25 units taller than the thing in the center, so that the player won't slide off the platform (could also make the things nogravity for floating moving platforms). So it's like:

XXX
XOX
XXX

X are the taller things
O is the shorter thing that the player stands on

Share this post


Link to post

Yeah, my last post was bologna. The things don't thrust if you're standing in front of it. So, while the platform is moving, if you touch the "barrier" things at the back of the platform, they'll just stop moving. So it's like:

XXX
XO        X
XXX
The platform is moving west, but you touched the back barrier (X) and it stopped moving.

Share this post


Link to post

All this talk of moving vehicles reminded me of Duke 3D -- which raises the question, is there a comparable community for Duke maps?

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×