subway

If you're looking for mapping help or you reckon you're a mapping guru, post your questions / solutions here

Moderator: Moderators

Post Reply
SlasherZ
Colonel
Posts: 433
Joined: Fri Jul 11, 2003 12:55 pm
Contact:

subway

Post by SlasherZ »

i'm making a map w/a subway... is there a way to have it where you can go in the subway car and be transported to the other end of the map?
User avatar
m0g
Lieutenant Colonel
Posts: 407
Joined: Fri May 23, 2003 10:11 am
Location: Sweden
Contact:

Post by m0g »

Here's something tltrude made, might give you a hint on how to:

viewtopic.php?t=3881
SlasherZ
Colonel
Posts: 433
Joined: Fri Jul 11, 2003 12:55 pm
Contact:

Post by SlasherZ »

thanks
User avatar
tltrude
Chuck Norris
Posts: 4774
Joined: Sun Jul 07, 2002 4:03 am
Location: Oklahoma, USA
Contact:

turns

Post by tltrude »

You can do it much easier if the subway car does not make any turns. If it doesn't, you can use waypoints--like an elevator moving sidways.

There is a teleport trigger too that will just make the player pop to the new location. So, for example, if you had two subway cars, you could make the player jump from one to the other and make it look like he is still in the first car, but at a new station.
Last edited by tltrude on Wed Jul 16, 2003 4:54 pm, edited 1 time in total.
Tom Trude,

Image
SlasherZ
Colonel
Posts: 433
Joined: Fri Jul 11, 2003 12:55 pm
Contact:

Post by SlasherZ »

it is striaght... how do i do waypoints?
User avatar
tltrude
Chuck Norris
Posts: 4774
Joined: Sun Jul 07, 2002 4:03 am
Location: Oklahoma, USA
Contact:

Script_object

Post by tltrude »

To use waypoints, you have to make the subway car a script_object. Then place a waypoint in the center of it and one down the track at the destination centerpoint.

Your script would have lines like this:

subway:

$subway_car speed 150 // units per second
$subway_trigger waittill trigger
wait 2
$subway_car moveto $way_2
$subway_car waitmove
wait 10
$subway_car moveto $way_1
$subway_car waitmove
goto subway

end

The above thread is very basic and has no sound or doors.
Tom Trude,

Image
SlasherZ
Colonel
Posts: 433
Joined: Fri Jul 11, 2003 12:55 pm
Contact:

Post by SlasherZ »

i need doors just basic sliding ones... and how do i make a srcipt object?
User avatar
tltrude
Chuck Norris
Posts: 4774
Joined: Sun Jul 07, 2002 4:03 am
Location: Oklahoma, USA
Contact:

Script_object

Post by tltrude »

Highlight all the brushes in the car (except the doors) and hit key N. Then find script_object on the list and double click on it. Next add Key: targetname and Value: subway_car.

subway_prep:

$subway_car speed 150 // units per second
$subdoor_left bind $subway_car
$subdoor_right bind $subway_car
$subway_trigger bind $subway_car
$subdoor_left open
$subdoor_right open
goto subway

subway:

$subway_trigger waittill trigger // trigger_use inside the car
wait 1
$subdoor_left close
$subdoor_right close
$subway_car loopsound lighthouse_run
$subway_car moveto $way_2
$subway_car waitmove
$subway_car loopsound lighthouse_run wait
$subdoor_left open
$subdoor_right open
wait 10
$subdoor_left close
$subdoor_right close
$subway_car loopsound lighthouse_run
$subway_car moveto $way_1
$subway_car waitmove
$subway_car loopsound lighthouse_run wait
$subdoor_left open
$subdoor_right open
goto subway

end


IF this is your first map, you are jumping into the deep end before you learn how to swim!
Last edited by tltrude on Wed Jul 16, 2003 5:41 pm, edited 1 time in total.
Tom Trude,

Image
SlasherZ
Colonel
Posts: 433
Joined: Fri Jul 11, 2003 12:55 pm
Contact:

Post by SlasherZ »

no, i just am clueless about scripting
User avatar
tltrude
Chuck Norris
Posts: 4774
Joined: Sun Jul 07, 2002 4:03 am
Location: Oklahoma, USA
Contact:

start the thread

Post by tltrude »

To start the thread you put:

Main:

level waittill prespawn
thread subway_prep

level waittill spawn

end

The doors should be closed in the map. They will be opened in the preperation thread (I updated it).
Last edited by tltrude on Wed Jul 16, 2003 5:50 pm, edited 2 times in total.
Tom Trude,

Image
SlasherZ
Colonel
Posts: 433
Joined: Fri Jul 11, 2003 12:55 pm
Contact:

Post by SlasherZ »

thanks
SlasherZ
Colonel
Posts: 433
Joined: Fri Jul 11, 2003 12:55 pm
Contact:

Post by SlasherZ »

what do i do about the doors and can i have a button to make it go?

-NTLS (Needs to Learn Scripting)
User avatar
tltrude
Chuck Norris
Posts: 4774
Joined: Sun Jul 07, 2002 4:03 am
Location: Oklahoma, USA
Contact:

func_door

Post by tltrude »

What? You don't know how to make function doors?

Put origin brushes on the sides and set the angle each will side to. Also set them to "targeted".
Tom Trude,

Image
SlasherZ
Colonel
Posts: 433
Joined: Fri Jul 11, 2003 12:55 pm
Contact:

Post by SlasherZ »

i do :) , but how do they follow the car? and can i have a button to make the subway car go?
User avatar
tltrude
Chuck Norris
Posts: 4774
Joined: Sun Jul 07, 2002 4:03 am
Location: Oklahoma, USA
Contact:

Post by tltrude »

These lines make the doors and trigger go with the car:

$subdoor_left bind $subway_car
$subdoor_right bind $subway_car
$subway_trigger bind $subway_car

And, if you ask me how to make a trigger_use, I QUIT! ha ha.
Tom Trude,

Image
Post Reply