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 / Entity Paths, Physics and Collisions - help?

Author
Message
uman
Retired Moderator
20
Years of Service
User Offline
Joined: 22nd Oct 2004
Location: UK
Posted: 29th Sep 2005 21:54
I have a problem I have been trying to overcome that after much effort have come to the conclusion that it cant be achieved....

What I am trying to achieve would be a realtively simple operation in most game engines but due to the inflexibilities and very limited capabilities in these areas of FPSC it becomes a complicated major undertaking.........

What I need to achieve is this....

I have a train station that has a monorail. I want a train to move from one end of the station to the other. That sounds easy right? well in my case no actually very difficult in FPSC.

Now it gets complicated....

The train is a monorail type so it runs (sits) over a single upright rail. The train therefore is if you like embedded over the top of the rail. As its a train station the rail and train are positioned around 2 foot below a platform which is a standard FPSC floor level which is what the Player and pedestrians if you lke walk on.

Now perhaps you may see some difficulties in achieving this - rather unauthordox expectations of FPSC.

Firstly an FPSC path can only be place at one floor level or another - I dont see any way of changing this. Moving the train position vertically of course is easy enough but FPSC always wants to plae an object on a path at floor level and not below - the levels of available path control and positioning in FPSC are non existant. Moving the train without path via scripting is a possibility but then consider the problem that FPSC wont allow one dynamic object like the train to move over another while sitting astride it - the rail (whether static or not). The collision of the two objects however you try to set them up is incompatable.

These difficulties have been made worse by the inclusion of Physics which introduces futher complications.

Thats just a brief outline of the difficulties I have encountered with this over almost a week of effort. Many hundreds of test runs in editor following much tweaking of scripts, settings and entity models.

Basically as far as I can see it not achievable.

If anyone has achieved this kind of interaction or would like to test this out by using two simple entities and see if they could achieve any success I would be pleased for the help.

Anyone have a script that moves an entity from A to B in a straight line? without the use of paths - that would be very helpful - at least that would be a start - removing one problem leaving just collision interaction and any Physics issues.

Thanks

Zero #43
20
Years of Service
User Offline
Joined: 5th May 2004
Location: ** in your head **
Posted: 29th Sep 2005 22:15
turn physics off

Intel® Pentium® 4 Processor w/ HT Technology 3.4GHz 800MHz FSB w/ 512KB Cache, 1GB DDR PC-2700 at 333MHz - 1x1024 SO-DIMM, ATI RADEON™ 9550 256MB DDR(<<soon ), 80GB Hard Drive
BULLSHOCK 2
Retired Moderator
19
Years of Service
User Offline
Joined: 14th Jun 2005
Location: Shocking Bulls
Posted: 29th Sep 2005 22:22
i made a train like the one in terminal (if you played halo2) i put 2 bars with an alpha channel for the texture so that they were invisible...then i made the train a charecter, and made it follow way points...let me see if i can find that...it was a long time ago...

I am really BULLSHOCK, but my profile got deleted...really, i'm telling the truth!
uman
Retired Moderator
20
Years of Service
User Offline
Joined: 22nd Oct 2004
Location: UK
Posted: 29th Sep 2005 22:43
Zero #43

Quote: "turn physics off "


Its vastly more complicated than that. Did you think I have not tried that and many hundeds of other permutations. I would not be posting here if it was just a simple matter.

BULLSHOCK 2,

Thanks for that - Following way points is not a problem of course - just in the situation as described. In FPSC trying to force an object to follow waypoints below floor level does not seem to be achievable. It seems that FPSC ignores for instance a models centre or axis vertex and calculates a point at the bottom of a model so no matter how its created in a model editor you cant force it to follow a path and have it appear to be even partly below floor level. Having an object sit below floor level in FPSC works fine - as soon as you attach it to a path however it jumps to floor height which is the default for path following.

Path points cannot be moved vertically so as to place the path at a height of your choosing...just some of the default restrictions which cause difficulties if you want to get creative.


Merranvo
19
Years of Service
User Offline
Joined: 24th May 2005
Location: That ^ is a Orange
Posted: 30th Sep 2005 00:14
hmm... I say it can be done.

it is easyer if it is a strait line, but here is a script IDEA...

place a trigerzone at any point that it would turn at.
have activated=1 turn left, activated=2 turn right
have the rail move forward always until activated=3.

Merranvo, taking over the net, one forum at a time.

"ye oft de adopte early shalt move mountains, and be gods among men"
Flash
19
Years of Service
User Offline
Joined: 31st Mar 2005
Location:
Posted: 30th Sep 2005 00:27
Could you not place the train and tracks at floor level then place the walkway/platform above floor level?

Hippopottomonstrosesquippedaliophobia
uman
Retired Moderator
20
Years of Service
User Offline
Joined: 22nd Oct 2004
Location: UK
Posted: 30th Sep 2005 00:44
Merranvo,

Thanks for that - yes I had already thought about and started scripting a move scripts as the train only has to move from one point to another - just two points - in a straight line.

To achieve that I could just use a path - that works fine under normal circumstances. Path or move by script command makes no difference as the second problem of collision is a killer.

i.e. in a test I have two objects :

Object one : Train on path however the forward movement is generated (path or script).

Object two : Train rail. The train moves forward however when its centre point (long object) hits the train rail it cannot function further.

Example if the rails are static the train stops completely. If the rails are dynamic the train bounces up over them (good for derailment - thats an idea)

Altering various settings such as the dynamic, static, collison and Physics attributes of each object in various permutations, plus numerous additional attempts at control scripts for each object have resulted in failure. Every time one parameter is changed it throws up new problems - fix one and the other comes back. I have not yet found a successful combination of settings or commands.

Simply put a script that would allow two objects one to move over or through the other without undue effects is whats needed. That seems to be impossible.

There are a lot of congflicting influences - not an easy thing to achieve it seems.

Bit of a nightmare - Worn myself out so will have another go when I catch my breath.

uman
Retired Moderator
20
Years of Service
User Offline
Joined: 22nd Oct 2004
Location: UK
Posted: 30th Sep 2005 00:59 Edited at: 30th Sep 2005 01:09
Flash,

Quote: "Could you not place the train and tracks at floor level then place the walkway/platform above floor level?"


Good thinking, if you could get around to designing a level where all other segments could be created or built around the tracks at non standard tile heights perhaps.

Actually the floor and rails being placed 2 foot below the platform currently themselves I have had to make both as entity pieces as FPSC wont allow a floor to be placed above midway in a level. I tried making a segment like that (floor height=80/or -20) for this situation and for some unknown reason to me FPSC wont allow it - it will place the segment OK as I can do it however a floor placed in a segment in this way causes that floor and all walls around it to flicker in and out of invisibility when the player gets anywhere near them i.e. engine draws them, then dont. Its a segment visibilty problem obviously. Perhaps building segments from scratch in the segment editor may overcome this prob if you could address this issue that way.

Building everything from entities may be a way around it as long as you can overcome any other difficulties that that would bring up and its not as successful building whole levels with many hundreds of entities which you could indeed place anywhere as opposed to segments which you cant. Segments for walls and stuff render better too without glitches.

FPSC is very unkind if you dont stick to the rules. e.g. keep it basic and simple - trying to be clever or creative causes all sorts of headaches. I could have easily made a game for all you guys by now if I stuck to the rules but dont see why we should not be able to achieve better than the default will allow - otherwise I would never release anything anyway.

Merranvo
19
Years of Service
User Offline
Joined: 24th May 2005
Location: That ^ is a Orange
Posted: 30th Sep 2005 01:05
::nogravity
:raycastdown=0 15:moveup=1
:noraycastup=-15 -14:moveup=-2

should make it float and fall...

general idea

Merranvo, taking over the net, one forum at a time.

"ye oft de adopte early shalt move mountains, and be gods among men"
uman
Retired Moderator
20
Years of Service
User Offline
Joined: 22nd Oct 2004
Location: UK
Posted: 30th Sep 2005 01:13
Thanks for that I will keep those snippets and try see if I can work them in somehow.

If I get it to work theres a video coming soon. I need to snap one of the train moving through the station.

uman
Retired Moderator
20
Years of Service
User Offline
Joined: 22nd Oct 2004
Location: UK
Posted: 30th Sep 2005 03:31
OK,

Thanks for all your help. After a weeks work making the train model, texturing it and fighting to get it to work - it finally does.

Running on a path it will indeed sit below default floor level - the rails were the main problem. For those it may help.

Train : set as standard dynamic object : Physics off and all settings set to zero except Physics Weight which can be any positive figure - if set to zero even with the Physics set to off it floats away somewhere and dissapears from the level. So has to have a positive figure in the weight.

Rails : This is how I got it to work : Static=No, Isimobile =Yes, Physics all off and zero figures. Uses scripts: Start=Appear1. Main = the trick is to use a simple script to call coloff and a suspend command which effectively kills the entity leaving it visible and removes its interaction with any other entity thus cancelling out any influence the static/dynamic properties might have. This is what caused the main difficulties. Fixing the collison problems the rails caused sorted the problem. No collision - no problem.

Someone else here asked a question recently about static/dynamic entities and collision which they could not get to work, so add the suspend command and that should fix the problem.

Cheers all

Matinuker
20
Years of Service
User Offline
Joined: 25th Mar 2004
Location:
Posted: 30th Sep 2005 23:11
Sounds very good. Upload teh level, scripts and media (if you wouldn't mind)
Please
Merranvo
19
Years of Service
User Offline
Joined: 24th May 2005
Location: That ^ is a Orange
Posted: 30th Sep 2005 23:22
Congrats Uman!

Merranvo, taking over the net, one forum at a time.

"ye oft de adopte early shalt move mountains, and be gods among men"

Login to post a reply

Server time is: 2024-11-24 00:15:25
Your offset time is: 2024-11-24 00:15:25