View previous topic :: View next topic |
Author |
Message |
KSAProdozul
Joined: 11 Aug 2005 Posts: 170 Location: In between Here and the There but close by Nowhere
|
Posted: Wed Jan 28, 2009 3:51 am Post subject: Need help with some scripting |
|
|
Well my first problem seems to be with some jumpboots that I would like to modify so that they can give the player some more speed great height when they jump and more control when they jump.
And for my other scripting problem I would like to make some jet boots so they player can fly around.
If anyone can point out some tutorials or some examples to look at then it would be greatly appreciated thanks. _________________
|
|
Back to top |
|
|
mental-HunteR
Joined: 05 May 2006 Posts: 363 Location: The Netherlands
|
Posted: Wed Jan 28, 2009 1:36 pm Post subject: |
|
|
This is from some old boots i made once, some ammounts are extremely high, but that's because the boots were really good etc..
Copy and paste the normal jump boots script and only replace state activated and state deactivated with these and it should work..
I put some extra things in to like UnderWaterTime, WaterSpeed and AirSpeed, but you can always remove those if you want.
Code: |
state activated
{
function beginstate()
{
bActive = True;
Pawn(owner).AirControl = 1.0;
Pawn(owner).JumpZ = 2000;
Pawn(owner).Groundspeed = 1150;
Pawn(owner).UnderWaterTime = 9999999;
Pawn(owner).WaterSpeed = 2200;
Pawn(owner).AirSpeed = 1000;
Owner.PlaySound(ActivateSound);
}
function endstate()
{
bActive = False;
Pawn(owner).AirControl = Pawn(Owner).Default.AirControl;
Pawn(owner).JumpZ = Pawn(Owner).Default.JumpZ;
Pawn(owner).Groundspeed = Pawn(Owner).Default.Groundspeed;
Pawn(owner).UnderWaterTime = Pawn(Owner).Default.UnderWaterTime;
Pawn(owner).WaterSpeed = Pawn(Owner).Default.WaterSpeed;
Pawn(owner).AirSpeed = Pawn(owner).Default.AirSpeed;
Owner.PlaySound(DeActivateSound);
}
}
state deactivated
{
}
|
And about the jet pack thing uhm,
i never made anything like it but i think i can do it. _________________
|
|
Back to top |
|
|
KSAProdozul
Joined: 11 Aug 2005 Posts: 170 Location: In between Here and the There but close by Nowhere
|
Posted: Wed Jan 28, 2009 9:02 pm Post subject: |
|
|
Thx mental.
But you don't have to make them. I was just asking for some guidance XD _________________
|
|
Back to top |
|
|
Bleeder91
Joined: 28 Sep 2006 Posts: 265
|
Posted: Thu Jan 29, 2009 5:10 pm Post subject: |
|
|
if you want that the boots allow you to fly without being admin, try looking at the exec function Fly() command in the playerpawn script.
other way flying would be like this in Tick():
Code: |
playerpawn(owner).AddVelocity(vector(owner.Rotation)*5)
|
or sumthing. just tell me when im talking rubbish again ;P _________________ Unreallity - Wrath of the Skaarj is still developing! Check out the new refreshing website!
|
|
Back to top |
|
|
KSAProdozul
Joined: 11 Aug 2005 Posts: 170 Location: In between Here and the There but close by Nowhere
|
Posted: Sat Jan 31, 2009 4:53 am Post subject: |
|
|
Well I was looking at the fly script to see if i that could take me anywhere and what I came across was
bcanfly=true?
Would that do anything to the jumpboots? _________________
|
|
Back to top |
|
|
Bleeder91
Joined: 28 Sep 2006 Posts: 265
|
Posted: Sat Jan 31, 2009 12:26 pm Post subject: |
|
|
bCanFly, bCanSwim and such only affects pawns. they only tell something about the pawn, like for the Fly pawn:
this means the Fly cant swim, and so it will avoid any contact with water. i noticed that several times, it keeps hovering around till your head pops up so it can sting your brains out >..< well anyway, it wont do anything usefull _________________ Unreallity - Wrath of the Skaarj is still developing! Check out the new refreshing website!
|
|
Back to top |
|
|
KSAProdozul
Joined: 11 Aug 2005 Posts: 170 Location: In between Here and the There but close by Nowhere
|
Posted: Sun Feb 01, 2009 6:06 pm Post subject: |
|
|
Bleeder91 wrote: | bCanFly, bCanSwim and such only affects pawns. they only tell something about the pawn, like for the Fly pawn:
this means the Fly cant swim, and so it will avoid any contact with water. i noticed that several times, it keeps hovering around till your head pops up so it can sting your brains out >..< well anyway, it wont do anything usefull |
Oh that's cool thx for telling me XD _________________
|
|
Back to top |
|
|
Bleeder91
Joined: 28 Sep 2006 Posts: 265
|
|
Back to top |
|
|
|