Login x
User Name:
Password:
Social Links Facebook Twitter YouTube Steam RSS News Feeds

Members Online

»
0 Active | 6 Guests
Online:

LATEST FORUM THREADS

»
warfare
CoD4 Map + Mod Releases
Voting menu on maps
CoD+UO General
Hauling 911
CoDBO3 General

Forums

»

Welcome to the MODSonline.com forums. Looking for Frequently Asked Questions? Check out our FAQs section or search it out using the SEARCH link below. If you are new here, you may want to check out our rules and this great user's guide to the forums and the website.
For more mapping and modding information, see our Wiki: MODSonWiki.com

Jump To:
Forum: All Forums : Call of Duty 2
Category: CoD2 Scripting
Scripting and coding with Call of Duty 2.
Moderators: foyleman, Foxhound, Mystic, StrYdeR, batistablr, Welshy, DrBiggzz, supersword, playername
Latest Posts
Subscribed Posts
Search
Restricted Access Topic is Locked subscribe
Author Topic: Elevator script/map
Zero_Rain
General Member
Since: Jun 5, 2006
Posts: 94
Last: Jan 13, 2008
[view latest posts]
Level 3
Category: CoD2 Scripting
Posted: Wednesday, Oct. 10, 2007 02:34 pm
can someone share with me a map with just an elevator with 5 stops includeing all the files .gsc etc.. I am making a large russian hotel prefab (9' between floors if thats helps) I want to share wih everyone so due credit will be given THANKS[thumbs_up]

Zerorain@gooutlawclan.com

edited on Oct. 10, 2007 10:35 am by Zero_Rain
Share |
Zero_Rain
General Member
Since: Jun 5, 2006
Posts: 94
Last: Jan 13, 2008
[view latest posts]
Level 3
Category: CoD2 Scripting
Posted: Wednesday, Oct. 10, 2007 06:52 pm
anyone?
Share |
kalieck
General Member
Since: Aug 9, 2006
Posts: 161
Last: Feb 14, 2009
[view latest posts]
Level 4
Category: CoD2 Scripting
Posted: Wednesday, Oct. 10, 2007 08:05 pm
i could give a script for the elevator:

main()
{
maps\mp\_load::main();
thread elevator();
}


elevator()
{
elevator = getent("elevator","targetname");

// thats your elevator; make your brushes for the elevator
// and select them all, right click on 2d view and say
// script-brushmodel. Then press n and give in as key
// "targetname" and as value "elevator"

start = getent("start","targetname");
// thats your trigger; make him trigger-use-touch or
// what you want


while(1)
{
start waittill ("trigger");
elevator moveZ (512,10,1,1);

//512=total-height, 10=total-time, 1=time to start/end
elevator waittill ("movedone");
}
}


for move down just make the same but use instead of 512, -512.

hope that helps!
[wave] kAlieck

edited on Oct. 10, 2007 04:06 pm by kalieck

edited on Oct. 10, 2007 04:07 pm by kalieck

edited on Oct. 10, 2007 04:08 pm by kalieck
Share |
94sniper
General Member
Since: Jun 15, 2007
Posts: 907
Last: Jun 22, 2009
[view latest posts]
Level 7
Category: CoD2 Scripting
Posted: Wednesday, Oct. 10, 2007 08:19 pm
I have completely mastered elevators. they're pretty easy, but sometimes good realistic elevators can take awhile to make. right now i'm working on a script for the elevator to have:

  1. inside doors
  2. outside doors on multiple levels
  3. ding! noise when floor is reached
  4. possibly a light to show what floor you're on.



I'm working on finding a good ding noise right now though. soon as I find one and get this down, I'll prolly make a zip file and a tut. yes, there's already a tut on that, but I'll make one that explains what everything does.
Share |
codmp
General Member
Since: Feb 7, 2006
Posts: 905
Last: Aug 1, 2011
[view latest posts]
Level 7
Category: CoD2 Scripting
Posted: Wednesday, Oct. 10, 2007 08:38 pm
Heres Tutorial:
http://www.modsonline.com/Tutorials-read-169.html

Some examples that might help:

http://www.modsonline.com/Downloads-full-3469.html

http://www.modsonline.com/Downloads-full-917.html



Some of these might be able to help you learn how to do it.
The code posted above should work, just follow the tutorial on how to set everything up mapping wise.

edited on Oct. 10, 2007 04:38 pm by codmp
Share |
playername
Preferred Member
Since: Aug 24, 2006
Posts: 821
Last: Apr 15, 2011
[view latest posts]
Level 7
Forum Moderator
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Tuesday, Oct. 16, 2007 01:53 am
kalieck, nothing wrong, but if you would please post any code in the [code ] and [/code ] tags that would be great. When you don't use those tags when the code is coppied, it doesn't coppy right. Also it helps keep the posts more orgainised and shorter.
Thanks[wink]
nullFew tips for coding.
1. Keep the script as short as possible.
2. Don't comment every line. Only comment portions where they may be needed to point something out.
3. Don't over complicate the script, keep it organized and easy to read.

These help you find simple errors and makes it easy to make changes.
Share |
kalieck
General Member
Since: Aug 9, 2006
Posts: 161
Last: Feb 14, 2009
[view latest posts]
Level 4
Category: CoD2 Scripting
Posted: Tuesday, Oct. 16, 2007 11:05 am
playername writes...
Quote:
kalieck, nothing wrong, but if you would please post any code in the [code ] and [/code ] tags that would be great. When you don't use those tags when the code is coppied, it doesn't coppy right. Also it helps keep the posts more orgainised and shorter.
Thanks[wink]

yes sir! [thumbs_up]
thanks for that [rolleyes]
Share |
Restricted Access Topic is Locked subscribe
MODSonline.com Forums : Call of Duty 2 : CoD2 Scripting

Latest Syndicated News

»
Codutility.com up and runn...
Nice, and there still using the logo and template for the screenshots, which...
Codutility.com up and runn...
dundy writes...Quote:Call of Duty modding and mapping is barly alive only a ...
Codutility.com up and runn...
Mystic writes...Quote:It seems to me the like the site is completely dead? ...
Codutility.com up and runn...
It seems to me the like the site is completely dead?

Partners & Friends

»