Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

FPSC Classic Scripts / Waypoint Height Script

Author
Message
Dillionaire
13
Years of Service
User Offline
Joined: 24th Dec 2010
Location: USA
Posted: 6th Jun 2011 18:49 Edited at: 6th Jun 2011 19:35
Hey, everyone.

I recently requested this script from 2beastmode4u, but since he's got a lot of stuff going on, he can't start writing it before Friday or Saturday.

So, I turn to the rest of the community for help. Hopefully you guys can come up with this script.

I would like a script that allows a dynamic entity, such as a cup, to follow a waypoint, except at a variable height from the ground that I can adjust. With the current "follow.fpi" script, the cup follows the waypoints, but it is stuck to the ground, or inside it, actually!

I would immensely appreciate it if one of you could come up with a script for this! Thanks in advance!

My Computer Specifications: Intel i7 980x OC @ 4.2 GHz |3x GTX 580's in SLI | 12 GB, 2000 MHz RAM (Corsair) |2x 1 TB HDD | 1.2 KW PSU |ASUS Rampage III Extreme Motherboard
Pirate Myke
14
Years of Service
User Offline
Joined: 31st May 2010
Location: El Dorado, Ca
Posted: 6th Jun 2011 21:02
Maybe this will work as the appear script.
It will keep it the height you set in the map editer.
Special instructions in the desc line. this file should be in your scriptbank root folder. their are two others also with slightly different meanings.



Nothing but coffee in my veins 'Insomnia is Coming'
Dillionaire
13
Years of Service
User Offline
Joined: 24th Dec 2010
Location: USA
Posted: 7th Jun 2011 19:09
It was a clever idea, but it sadly didn't work. The cup still followed the waypoint at ground level.

My Computer Specifications: Intel i7 980x OC @ 4.2 GHz |3x GTX 580's in SLI | 12 GB, 2000 MHz RAM (Corsair) |2x 1 TB HDD | 1.2 KW PSU |ASUS Rampage III Extreme Motherboard
2Beastmode4u
13
Years of Service
User Offline
Joined: 14th Feb 2011
Location: Loading...
Posted: 7th Jun 2011 22:40
Here is what I'd do.
In the start script use the moveup command however high that you want it to be, disable gravity from affecting it, and have the waypoint at the same level of the cup.


Cheers.

God help me, Please.

Come on down to my site at Unleashed FPSCreators
Dillionaire
13
Years of Service
User Offline
Joined: 24th Dec 2010
Location: USA
Posted: 7th Jun 2011 23:08
The thing is, you can't adjust the high of waypoints. They are always at the very bottom of whatever layer you place them in.

My Computer Specifications: Intel i7 980x OC @ 4.2 GHz |3x GTX 580's in SLI | 12 GB, 2000 MHz RAM (Corsair) |2x 1 TB HDD | 1.2 KW PSU |ASUS Rampage III Extreme Motherboard
2Beastmode4u
13
Years of Service
User Offline
Joined: 14th Feb 2011
Location: Loading...
Posted: 7th Jun 2011 23:10
That is where I'd use an invisible wall segment. Set the waypoint on it and watch as the cup mysteriously appears to float.


Cheers.

God help me, Please.

Come on down to my site at Unleashed FPSCreators
Dillionaire
13
Years of Service
User Offline
Joined: 24th Dec 2010
Location: USA
Posted: 7th Jun 2011 23:14
The thing is, I need to the cup to float mid-segment, say 3/4 the way up. If I wanted to make it a segment up, I'd just make a 2 layer room and delete the floor of the top layer, and put the waypoint in that layer. But, that's not gonna work for what I need. Any other ideas?

My Computer Specifications: Intel i7 980x OC @ 4.2 GHz |3x GTX 580's in SLI | 12 GB, 2000 MHz RAM (Corsair) |2x 1 TB HDD | 1.2 KW PSU |ASUS Rampage III Extreme Motherboard
2Beastmode4u
13
Years of Service
User Offline
Joined: 14th Feb 2011
Location: Loading...
Posted: 7th Jun 2011 23:26
3/4 of the way... do way point just look for the nearest thing blow them, because if so you could just get a model that high and make it invisible.


Cheers.

God help me, Please.

Come on down to my site at Unleashed FPSCreators
Pirate Myke
14
Years of Service
User Offline
Joined: 31st May 2010
Location: El Dorado, Ca
Posted: 7th Jun 2011 23:35
Can you post the entity and your script??

Nothing but coffee in my veins 'Insomnia is Coming'
Dillionaire
13
Years of Service
User Offline
Joined: 24th Dec 2010
Location: USA
Posted: 7th Jun 2011 23:51 Edited at: 7th Jun 2011 23:52
I was using the cup entity from the stock sci-fi entities, your appear script, the "follow.fpi" main script, and the regular destroy script.

EDIT: Beastmode, I thought about that, but the functionality I plan to use this for requires a bit more versatility than having to re-edit a model for height each time. You'll see, if we can get this working!

My Computer Specifications: Intel i7 980x OC @ 4.2 GHz |3x GTX 580's in SLI | 12 GB, 2000 MHz RAM (Corsair) |2x 1 TB HDD | 1.2 KW PSU |ASUS Rampage III Extreme Motherboard
Pirate Myke
14
Years of Service
User Offline
Joined: 31st May 2010
Location: El Dorado, Ca
Posted: 7th Jun 2011 23:58
OK cool I have all that. Working a solution now.

Nothing but coffee in my veins 'Insomnia is Coming'
2Beastmode4u
13
Years of Service
User Offline
Joined: 14th Feb 2011
Location: Loading...
Posted: 8th Jun 2011 00:00 Edited at: 8th Jun 2011 00:01
Well since you can't script for waypoints(that could be a nice addition), my ides before is all that I can think of. If you don't mind it being a bit higher than wanted I would just use the invisible floor thing. Or try rotating the floor to a position that suites you with the '1' and '2' keys. Or the hardest way of making a model for each one. Sorry, I can't think of anything else.


Cheers.

God help me, Please.

Come on down to my site at Unleashed FPSCreators
Pirate Myke
14
Years of Service
User Offline
Joined: 31st May 2010
Location: El Dorado, Ca
Posted: 8th Jun 2011 05:40 Edited at: 8th Jun 2011 06:23
Yea the scripts would not work. But moving the object up in a model program and exporting it in to the game engine faired well.

Video attached. I know you would rather not have to have all these things modeled out. But that seems to be the quickest solution.

I have these assets if you would like. The cup is rigged with bones that keep it at the right height.

Waypoints do the rest.

Nothing but coffee in my veins 'Insomnia is Coming'

Attachments

Login to view attachments
Ched80
14
Years of Service
User Offline
Joined: 18th Sep 2010
Location: Peterborough, UK
Posted: 8th Jun 2011 07:46
Have you thought about using the floatrate command? this will make the entity move up and down as it moves from waypoint to waypoint.

[url="http://raptr.com/No_Turn_Right?src=em_forum"][/url]
spudnick
13
Years of Service
User Offline
Joined: 30th Nov 2010
Location:
Posted: 20th Jun 2011 01:05 Edited at: 20th Jun 2011 12:51
@ched80 that is a brilliant idea. Just to let all know is the waypoints only work with floor segments

Meaning you need to have your way point along a floor.

I have my entity working and flying around, but you need to make some invisable floor segments or make some that looks a bit like clouds

unless their is a way by scripting but this is simple to do with stock contents.

ok here are settings.

I used the entity settings from Scfi,Scenery,Lifts,Antigrav Platform

So the scripts

Start: appearnogravity.fpi
Main: follow_and_float.fpi ( My script )
Destroy: Disapear1.fpi

or edit the stock Main: follownorotate.fpi script and insert this


at line 9
or after where it says ;triggers

To increase the floating above the ground then increase the FLOATRATE=0 to a higher number and if you would like it to float under the layer then enter FLOATRATE=-1 or any other number Note the Minus sign! after the equals.

Note the higher the number the more it will float up and down like a yoyo effect

Here is my complete script to use in MAIN


And i have included a invisable image, well it just has a dot in it so you can still see where you have put it.

Note when using the waypoint, make sure you have my invisable image on ever side of the way point when going diagonal, or the entity will stop moving.

Hope you all can enjoy this as it has made flying entities possiable for me and now for you

I'am not GOD but i can make you see again by taking my fingers out of your eyes and i can make you walk again by taking your beer away, So its nice to give!

Attachments

Login to view attachments
spudnick
13
Years of Service
User Offline
Joined: 30th Nov 2010
Location:
Posted: 20th Jun 2011 21:00 Edited at: 20th Jun 2011 21:20
Has any one tried this?

I'am not GOD but i can make you see again by taking my fingers out of your eyes and i can make you walk again by taking your beer away, So its nice to give!

Login to post a reply

Server time is: 2024-11-24 08:20:39
Your offset time is: 2024-11-24 08:20:39