Forums Index >> Modding >> Teleporter Script
Page : <1> :
Where do I p[ut it?
Heh, mines a little longer than that, but that will give alot of people a good starting block to improve it. :)
Gj 187.
-Michael
Wat iongh said, where do u put it?
I belive with hers you put that in a new file and save it as teleporter.cs, in game/server/scripts. Then exec it at the top of the.mis. Then where it says
};
New PowerUp() {
Position = "-211.225 81.8566 83.5943";
Rotation = "0 -1 0 6.30264";
Scale = "10 10 10";
DataBlock = "testpowerup";
LightBoost = "0";
Put
};
New PowerUp() {
Position = "-211.225 81.8566 83.5943";
Rotation = "0 -1 0 6.30264";
Scale = "10 10 10";
DataBlock = "bluesectorwarp";
LightBoost = "0";
Your Welcome. :)
-Michael
Well Michael I tried it like that but it didnt work :[........so I put each one of them on the top of the.mis file and then wat you said just change DATABLOCK to wich ever one your using :) it works great now so goodluck people :)
Great Billy. Like I said I wasnt sure about hers, but I said it like I do mine. :)
Hey billy, did you do exec("game/server/scripts/teleporter.cs"); ?
Yeah.......i tried it a couple of ways but it didnt work so I just put it at the top of my.mis file and did wat I said before :)
Ok.
Thanks for this 187, we are all VERY greatful, right little munchkins? *munchkin fan club starts yelling high pitched things indecioherably*...
The exec thing, do u put dat at the VERY top of da.mis file? Like b4 everything else? And for dat powerup thing, how u change the datablock, cud u be able to make a second powerup thing in the game/data/shapes/common and name it something like teleporter and make it look different so u know wich one it is in da game?
Dont use the exec thing just put that stuff at the top of your.mis file and then put down the position you want to be teleported to....... Then put a reload gate down with modwiz then go in and change the datablock of the reload gate to to wat ever it is that your using in this case you would put bluesectorwarp in the datablock of the reaload gate........i hope this helps :)
Last edited: Thursday, May 27, 2004 at 8:52:16 PM
Thanks I was waiting 4 this
Help it holds up while loading!! It says the name of the map but no loading objects, datablocks or anything like this and at the third consecutive try it crashes the game!!
Heres the code I putted:
Function bluesectorwarp::onenter(%db, %this, %tank)
{
%pos = %tank.getPosition();
%rot = %tank.Rotation;
%newPos = ("-697.35 92.149 135.004" @ " " @ %rot);
%tank.setTransform(%newPos);
};
Datablock powerupdata(bluesectorwarp)
{
Aipickup = 0;
Emitterduration = 0;
Maxoff = 100;
Minoff = 50;
Shadow = 1;
Shadowanimation = 1;
Shape = "game/data/shapes/common/recharge.dts";
Starton = 0;
Staticshadow = 0;
};
//--- OBJECT WRITE BEGIN ---
And:
New PowerUp() {
DataBlock = "bluesectorwarp";
Position = "-10.4173 -30.7067 139.61";
Rotation = "-0.0312004 0.0642388 0.997447 145.519";
Scale = "1 1 1";
LightBoost = "0";
Last edited: Friday, May 28, 2004 at 2:43:34 PM
There should be no capitals.
Ok, from wut billy said, I don't use the exec thing at all, I just use this
Function bluesectorwarp::onenter(%db, %this, %tank)
{
%pos = %tank.getPosition();
%rot = %tank.Rotation;
%newPos = ("-697.35 92.149 135.004" @ " " @ %rot);
%tank.setTransform(%newPos);
}
Datablock powerupdata(bluesectorwarp)
{
Aipickup = 0;
Emitterduration = 0;
Maxoff = 100;
Minoff = 50;
Shadow = 1;
Shadowanimation = 1;
Shape = "game/data/shapes/common/recharge.dts";
Starton = 0;
Staticshadow = 0;
};
Wit out da caps tho, and I put it b4 everything else in da.mis? And bout that reload gate thing, I'm confused :'(
Last edited: Friday, May 28, 2004 at 7:03:25 PM
I thought caps or not did'nt matter ?
Last edited: Friday, May 28, 2004 at 7:23:30 PM
Run a dedicated, and see if there are any errors.
Umm....... Im confused.... How do u set where ur tank goes?
Or is that in the code?
%newPos = ("-697.35 92.149 135.004"
Change the position to your liking.
I see thank you
I dont get number 8)
What am I doin wrong?
Here is the bluesectorwarp:
Function bluesectorwarp::onenter(%db, %this, %tank)
{
%pos = %tank.getPosition();
%rot = %tank.Rotation;
%newPos = ("31.8514 -141.112 122.003" @ " " @ %rot);
%tank.setTransform(%newPos);
}
Datablock powerupdata(bluesectorwarp)
{
Aipickup = 0;
Emitterduration = 0;
Maxoff = 100;
Minoff = 50;
Shadow = 1;
Shadowanimation = 1;
Shape = "game/data/shapes/common/recharge.dts";
Starton = 0;
Staticshadow = 0;
};
Here is the bluesectorwarp datablock:
new PowerUp() {
DataBlock = "bluesectorwarp";
Position = "-131.936 -613.979 123.608";
Rotation = "-0.652368 -0.0435052 0.756653 13.2285";
Scale = "1 1 1";
LightBoost = "0";
It just stops loading (it doesnt even start)
http://supra.planetthinktanks2.com/archives/about-dedicated.asp no ) at the end
Bump XD
I did exactly what max said and it still dont work. When I ran a ded. Server it said there war a error on the first line or something
More then that peanut can handle, I'm guessing...
More then that peanut can handle, I'm guessing...
Lmfao!!!
Page : <1> :
A lot of people have been asking about the teleporter script so here it is. Have fun friends!!!!!
Function bluesectorwarp::onenter(%db, %this, %tank)
{
%pos = %tank.getPosition();
%rot = %tank.Rotation;
%newPos = ("-697.35 92.149 135.004" @ " " @ %rot);
%tank.setTransform(%newPos);
}
Datablock powerupdata(bluesectorwarp)
{
Aipickup = 0;
Emitterduration = 0;
Maxoff = 100;
Minoff = 50;
Shadow = 1;
Shadowanimation = 1;
Shape = "game/data/shapes/common/recharge.dts";
Starton = 0;
Staticshadow = 0;
};