Door question that i saw in malta map

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

Moderator: Moderators

Post Reply
=Sgt. Daniel R. O*Neil=
Second Lieutenant
Posts: 172
Joined: Wed Nov 27, 2002 10:15 pm
Contact:

Door question that i saw in malta map

Post by =Sgt. Daniel R. O*Neil= »

I was coming down the stairs when i saw a door open upward from the ground. THATS COOL !! How do you do this? I tried shoving origin off to oneside while looking in a different view and i tried different angles. None of them seemed to do the trick. Any ideas? :idea:
"Sometimes to cause the biggest change in the world, is as something as small as saying "Hi" to someone, on a crowded bus"
jv_map
Site Admin
Posts: 6521
Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:

Post by jv_map »

Use a func_door with angle -1 (up, -2 is down). Design the door in a closed position.

The door will open if you walk close enough or shoot at it.

You may also target a trigger to the door, it won't respond to damage anymore if you do this.
Image
bobo

Door openning upwards

Post by bobo »

I tried to do this with a square panel on the ceiling to go to the attic using a latter. When I use func_door with the angle -1 (up) it only budges a bit like its going to open, but stops and the sound plays through.

I tried placing my origin at different places, i tried not using origin at all and to no success. i also tried all of the above with the rotatingdoor function and no luck there also.

Any one knows what I'm doing wrong?
jv_map
Site Admin
Posts: 6521
Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:

Post by jv_map »

Hmm the door should move up its own dimensions minus its lip value.

How tall is your door?
Image
bobo

size of door

Post by bobo »

the panel is 16 wide X 32 long.

what is this about calculating dimention?

actually if you want you can download the prefab at
http://www.alliedassault.us go in the prefab area and download the mansion. I gave up on it and left it at 90 deg. with the func_door.
TheStorm
Captain
Posts: 233
Joined: Mon Oct 07, 2002 7:45 am
Location: Gavle, Sweden
Contact:

Post by TheStorm »

Are you sure that the door you are talking about in Malta isn't a scripted door? The func for doors in mohaa doesn't work as some other games, like in RTCW where you can make a hatch using the func, that's not possible in mohaa, you must script it.
TMT admin, visit www.modtheater.com
HITP Lead Mapper
Member of Electronic Arts MOHteam
jv_map
Site Admin
Posts: 6521
Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:

Post by jv_map »

Well easy to find out, look at the script :D

Only don't have Spearhead demo anymore :(.

I recycled it :roll:
Image
User avatar
mohaa_rox
Field Marshal
Posts: 2760
Joined: Mon Nov 11, 2002 7:05 am
Contact:

Post by mohaa_rox »

Recycle? As in delete?
Live to map, not map to live.
-mohaa_rox, .map
moderator
TheStorm
Captain
Posts: 233
Joined: Mon Oct 07, 2002 7:45 am
Location: Gavle, Sweden
Contact:

Post by TheStorm »

This is from Malta, and I don't think it's the large metal gate that you can open and close (there is some other scripting for that) but I'm not sure

trapdoor_init:
self solid
self damage 0
level.trapdoor_state = 0
trapdoor_loop_start:
self waittill use
if (level.trapdoor_state == 0)
{
self thread trapdoor_open
}
else if (level.trapdoor_state == 1)
{
self thread trapdoor_close
}
goto trapdoor_loop_start
end

trapdoor_cycle local.duration:
wait local.duration
if (level.trapdoor_state == 1)
{
self thread trapdoor_close
}
end

trapdoor_open:
level.trapdoor_state = 1
self openportal
self playsound gate_wood_open_move
self rotatezupto 90
self time 1
self waitmove
self playsound gate_wood_open_stop
self thread trapdoor_cycle 15

end

trapdoor_close:
self playsound gate_wood_close_move
level.trapdoor_state = 0
self rotatezdownto 0
self time 1
self waitmove
self playsound gate_wood_close_stop
self closeportal
end
TMT admin, visit www.modtheater.com
HITP Lead Mapper
Member of Electronic Arts MOHteam
bobo

association

Post by bobo »

I guess I would put Targetname = trapdoor or something like that to associate it with the script?

thanks for your time people
TheStorm
Captain
Posts: 233
Joined: Mon Oct 07, 2002 7:45 am
Location: Gavle, Sweden
Contact:

Post by TheStorm »

This is from the :twisted: Malta (converted) map file...so you're right, trapdoor it should be!!

// Entity #2
{
"origin" "-2056 -2480 -1392"
"classname" "script_object"
"$targetname" "trapdoor"
TMT admin, visit www.modtheater.com
HITP Lead Mapper
Member of Electronic Arts MOHteam
jv_map
Site Admin
Posts: 6521
Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:

Post by jv_map »

Oops I thought you meant the large metal gate near the bridge that slides up or down if you press the button. :oops:
Image
Post Reply