FSIC Messageboard
  Tech Talk
  Calling dof's and input commands using obExec/Func

Post New Topic  Post A Reply
profile | register | preferences | faq | search

UBBFriend: Email This Page to Someone! next newest topic | next oldest topic
Author Topic:   Calling dof's and input commands using obExec/Func
Raider
Pilot
posted 09-01- 04:14 PM     Click Here to See the Profile for Raider   Click Here to Email Raider     Edit/Delete Message   Reply w/Quote
This may be old news, but I just figured it out.

Last year we were trying to figure out how to make Dirk slump over in the cockpit when he was hit. Well here it is.

This works to call dof's or anything on your keyboard.inp


XXXX is the "Name" of your Parent Object
YYYY is the "Func"
ZZZZ is the command like "cmdDoorOpen" or "cmdRoll" or "inpFeatherProp"

1. On the object you want to call the function from using obDetach, or onDmg;

onDmg 1 (obExec (Name 'XXXX Func 'YYYY)

2. In your Parent Object;

(obFunc (YYYY(cmdZZZZ)))

This has to be in the Parent Object, it is as if you pressed a key to call a command.

3. On the dof you want to call

(dofID 'openup dofOsc (oscName 'openup oscDelayBgn 0 oscRuntime 2.0 oscDelayEnd 0 oscParent 'XXXX oscCmd 'cmdZZZZ 'cmdRunReverse)

You do not even have to add cmdZZZZ to the keyboard.inp

If you want to use a call that is in the keyboard.inp just use the name like

'cmdDoorOpen or 'inpFeatherProp

If you use a command that is in the keyboard.inp the player can reverse it by pressing that key command if it is set to toggle, but if you use one that is not on the keyboard.inp the player can not reverse it. However you can add the same function call again, like onDmg2 and it is like pressing the key for it again.

I hope to use this to get ol'Dirk to slump over in the cockpit, and see if this works in the Dauntless swing arm for the bomb.

This all started from trying to get the canopy to open before the pilot jumps out. Not there yet, but I'm trying.
------------------
Raider 33rd~GS
Raiders Site

[This message has been edited by Raider (edited 09-01-2000).]

IP: Logged

charmstar
Pilot
posted 09-01- 06:13 PM     Click Here to See the Profile for charmstar   Click Here to Email charmstar     Edit/Delete Message   Reply w/Quote
Wow! So the trick is calling the obFunc in the parent object... good job figuring that one out!
Now I'm wondering if you can use that oscEndDisable command to render an object's other DOFs unusable. What I'm thinking is it would be sweet if you shot the wing, and that called a DOF which lowered the gear a certain amount on that side, and disabled the existing DOF for the gear so it couldn't go back up. This would simulate a loss of hydraulics by that wheel. However, I don't really know what effect disabling would have on the wheel.

cheers,
charm

IP: Logged

charmstar
Pilot
posted 09-01- 06:16 PM     Click Here to See the Profile for charmstar   Click Here to Email charmstar     Edit/Delete Message   Reply w/Quote
Also, about the pilot jumping out: Couldn't you add a DOF for the canopy sliding which is tied to the bail out key? If so, then all you'd have to do is figure a way to delay the guy jumping, and the parachute opening...

While you're at it, you could add an obProb to the parachute so there's a chance it wouldn't open (pilot unconscious or failed parachute).

charm

IP: Logged

Raider
Pilot
posted 09-01- 10:26 PM     Click Here to See the Profile for Raider   Click Here to Email Raider     Edit/Delete Message   Reply w/Quote
Charm, I can get the pilot to bail when the canopy opens, I used a different dof for this so you could still open the canopy if you want.

I seem to remember that MH said you could call a dof from another dof, I haven't figured that out yet. So I am using bjorn's trick of enabling a drag point to detach when you open the canopy, when it detaches it calls for the bail out.

The trouble I am having right now is that I can't get it to delay, the canopy starts to open and out comes the pilot. I have to work on oscBeginDisabled/EndDisabled to get it right. I will let you know if I have any success.

Let me know if you can disable another dof that would be cool.

------------------
Raider 33rd~GS
Raiders Site

IP: Logged

charmstar
Pilot
posted 09-03- 02:20 AM     Click Here to See the Profile for charmstar   Click Here to Email charmstar     Edit/Delete Message   Reply w/Quote
Hey Raider-
I'm almost sure you can set up delays as you are talking about: some people made complex gear retraction sequences that involve a couple DOFs I believe... I can't remember how to do it off the top of my head though.

charm

IP: Logged

Ronin
Pilot
posted 09-03- 01:05 PM     Click Here to See the Profile for Ronin   Click Here to Email Ronin     Edit/Delete Message   Reply w/Quote
Hey Raider! I sure appreciate you sharing all these little gems. The all get printed and added to my SDOE OpenPlane noteboook!

Ronin

IP: Logged

jedi
Pilot
posted 09-04- 09:56 AM     Click Here to See the Profile for jedi   Click Here to Email jedi     Edit/Delete Message   Reply w/Quote
I'm pretty sure that in almost every case, the pilot simply JETTISONNED the canopy for bailout. Most of our canopy DOFs take 1-3 seconds to function.

Make your drag-point DOF act VERY fast, so the canopy just comes off as the pilot bails.

More realistic that way anyhow IMO

------------------
--jedi--

IP: Logged

Raider
Pilot
posted 09-04- 10:06 AM     Click Here to See the Profile for Raider   Click Here to Email Raider     Edit/Delete Message   Reply w/Quote
LOL, good point jedi, and a lot easier to implement, thanks.

Ronin, you are sure welcome, the more we know the better our planes get. That must be some notebook.

------------------
Raider 33rd~GS
Raiders Site

IP: Logged

All times are CT (US)

next newest topic | next oldest topic

Administrative Options: Close Topic | Archive/Move | Delete Topic
Post New Topic  Post A Reply
Hop to:

Contact Us | Fighter Squadron Information Center

(This site Copyright (c) 1999 Inertia LLC)

Powered by Infopop www.infopop.com © 2000
Ultimate Bulletin Board 5.45c