help me asap!
Moderator: Core Staff
help me asap!
i was making a map and ending it and i was sooooo excited.. when i finished it i turned of pure and type /map mp_school it did not work from script compile error.. syntax maps\mp\teleportenter::main();i was soooo mad so i went into my gsc and removed it... my map worked but my teleports didnt, now i dont know how to put it in my gsc to make my teleports and my map work. HELLP!! here is my gsc just incase something is wrong
main() {
maps\mp\_load::main();
maps\mp\teleportenter::main();
thread door1_rotate();
thread door2_rotate();
}
door1_rotate()
{
door1 = getent("door1", "targetname");
trig = getent("door_trigger1", "targetname");
while (1)
{
trig
waittill("trigger");
door1 rotateYaw(90, 1.5, 0.7, 0.7);
door1 waittill("rotatedone");
wait (3);
door1 rotateYaw(-90, 1.5,
0.7, 0.7);
door1 waittill("rotatedone");
}
}
door2_rotate()
{
door2 = getent("door2", "targetname");
trig =
getent("door_trigger2", "targetname");
while (1)
{
trig waittill("trigger");
door2 rotateYaw(90, 1.5, 0.7, 0.7);
door2
waittill("rotatedone");
wait (3);
door2 rotateYaw(-90, 1.5, 0.7, 0.7);
door2 waittill("rotatedone");
}
}
main() {
maps\mp\_load::main();
maps\mp\teleportenter::main();
thread door1_rotate();
thread door2_rotate();
}
door1_rotate()
{
door1 = getent("door1", "targetname");
trig = getent("door_trigger1", "targetname");
while (1)
{
trig
waittill("trigger");
door1 rotateYaw(90, 1.5, 0.7, 0.7);
door1 waittill("rotatedone");
wait (3);
door1 rotateYaw(-90, 1.5,
0.7, 0.7);
door1 waittill("rotatedone");
}
}
door2_rotate()
{
door2 = getent("door2", "targetname");
trig =
getent("door_trigger2", "targetname");
while (1)
{
trig waittill("trigger");
door2 rotateYaw(90, 1.5, 0.7, 0.7);
door2
waittill("rotatedone");
wait (3);
door2 rotateYaw(-90, 1.5, 0.7, 0.7);
door2 waittill("rotatedone");
}
}
!TUTORIAL for adding teleports to COD2!
Open your map in the editor.
Navigate to the position you want to be teleported from.
Create a large trigger (about the size of an actor).
With the trigger still selected, right click in the 2D view and select trigger_multipple.
Still with the trigger selected press n.
In the key field type targetname.
In the value field type enter, press [enter]
Now in the key field type target
In the value field type a name for the area you want to teleport to lets say for example tower press [enter] then [esc]
THATS IT FOR THE TRIGGER
Now navigate to the area you want to be teleported to.
Right click in the 2D view and select script_origin.
Position the small red cube slightly above ground or floor and not intersecting with any other brush, rotate it so the arrow points in the direction you wish to face.
With the script_origin still selected press n.
In the key field type targetname.
In the value field type tower (or whatever you chose for the target when you made the trigger) press [enter].
If you have everything correct you should now see a red "connection" line with arrows running from the trigger to the origin.
Here is a hint from Cybershot, if you dont see a red line connecting the trigger to the origin select both and press the "w" key. If you now see the red line but dont have the arrows on it pointing from trigger to origin then recheck the targetnames and target for any typo's.
THATS IT FOR THE MAPPING (save and compile)
Extract and use the teleportenter.gsc from this zip file. Place it in your maps\mp folder.
Add this line to yourmapname.gsc
maps\mp\teleportenter::main(); //this calls up the teleportenter.gsc If you are unsure where to add this line simply look in the mp_cod2teleportdemo.gsc enclosed in this zip.
Also included in this zip is the mp_cod2teleportdemo.map file. If need be you can load this up in the editor to get a better idea of how to add teleporting.
Example Download
If you require more teleports in your map simply follow the above procedure, always give the trigger the targetname of enter but make the target the same as the next script_origins targetname.
To load the cod2teleportdemo map in your game extract the cod2teleporttutorialanddemomap.IWD into your COD2\main folder, start game, select start server, mahe pure no, dedicated no, select death match, scroll down map list and select COD 2 teleport demo, start.
Many thanks to modsonline member cybershot for help with the scripting and testing.
Dadofazz
i used that from modsonline.com and my teleports where working earlieri also dont have a teleportenter.gsc... if i need that please post me what i need to put into it
Open your map in the editor.
Navigate to the position you want to be teleported from.
Create a large trigger (about the size of an actor).
With the trigger still selected, right click in the 2D view and select trigger_multipple.
Still with the trigger selected press n.
In the key field type targetname.
In the value field type enter, press [enter]
Now in the key field type target
In the value field type a name for the area you want to teleport to lets say for example tower press [enter] then [esc]
THATS IT FOR THE TRIGGER
Now navigate to the area you want to be teleported to.
Right click in the 2D view and select script_origin.
Position the small red cube slightly above ground or floor and not intersecting with any other brush, rotate it so the arrow points in the direction you wish to face.
With the script_origin still selected press n.
In the key field type targetname.
In the value field type tower (or whatever you chose for the target when you made the trigger) press [enter].
If you have everything correct you should now see a red "connection" line with arrows running from the trigger to the origin.
Here is a hint from Cybershot, if you dont see a red line connecting the trigger to the origin select both and press the "w" key. If you now see the red line but dont have the arrows on it pointing from trigger to origin then recheck the targetnames and target for any typo's.
THATS IT FOR THE MAPPING (save and compile)
Extract and use the teleportenter.gsc from this zip file. Place it in your maps\mp folder.
Add this line to yourmapname.gsc
maps\mp\teleportenter::main(); //this calls up the teleportenter.gsc If you are unsure where to add this line simply look in the mp_cod2teleportdemo.gsc enclosed in this zip.
Also included in this zip is the mp_cod2teleportdemo.map file. If need be you can load this up in the editor to get a better idea of how to add teleporting.
Example Download
If you require more teleports in your map simply follow the above procedure, always give the trigger the targetname of enter but make the target the same as the next script_origins targetname.
To load the cod2teleportdemo map in your game extract the cod2teleporttutorialanddemomap.IWD into your COD2\main folder, start game, select start server, mahe pure no, dedicated no, select death match, scroll down map list and select COD 2 teleport demo, start.
Many thanks to modsonline member cybershot for help with the scripting and testing.
Dadofazz
i used that from modsonline.com and my teleports where working earlieri also dont have a teleportenter.gsc... if i need that please post me what i need to put into it

Watch this before posting a question: http://www.albinoblacksheep.com/flash/posting.php
Re: help me asap!
KillerSam meant to change it to what you see above.main()
{
maps\mp\_load::main();
maps\mp\teleportenter::main();
thread door1_rotate();
thread door2_rotate();
}
door1_rotate()
{
door1 = getent("door1", "targetname");
trig = getent("door_trigger1", "targetname");
while (1)
{
trig waittill("trigger");
door1 rotateYaw(90, 1.5, 0.7, 0.7);
door1 waittill("rotatedone");
wait (3);
door1 rotateYaw(-90, 1.5, 0.7, 0.7);
door1 waittill("rotatedone");
}
}
door2_rotate()
{
door2 = getent("door2", "targetname");
trig = getent("door_trigger2", "targetname");
while (1)
{
trig waittill("trigger");
door2 rotateYaw(90, 1.5, 0.7, 0.7);
door2 waittill("rotatedone");
wait (3);
door2 rotateYaw(-90, 1.5, 0.7, 0.7);
door2 waittill("rotatedone");
}
}


Who is online
Users browsing this forum: No registered users and 3 guests