Home   Help Search Login Register  

Author Topic: Executing an fx script on a game logic(complications)  (Read 619 times)

0 Members and 1 Guest are viewing this topic.

Offline Nemesis6

  • Members
  • *
Here's the thing - I'm executing the GMR dustwave script on a game logic. The script relies on whole cosine thing when it comes to particle velocity, so when planes crash, the dustwave often looks a bit awkward, so I'm trying it on a game logic(Hey, they face straight one way, right?), but the dustwave now appears behind the vehicle.... what's up with this? It works fine when I use a water-wave equivalent on the water, executing it on a game logic.


Please, don't ignore me... :/
I am actually flying into a star... this is incredible!

Offline Raptorsaurus

  • Editors Depot Staff
  • *****
Re:Executing an fx script on a game logic(complications)
« Reply #1 on: 11 Jan 2005, 04:04:38 »
Quote
(Hey, they face straight one way, right?)

Actually game logics can be setDir just like any other unit.  If you camcreate any unit it starts off by default facing North (0 degrees).

Since the drop command automatically references itself to the unit's direction and pitch, maybe this is throwing your trigonometry off (if you are trying to do the trig for the drop command, then the result would be very strange).  I had this problem when I fist started using the drop command.  I was making it more complex than I needed to.  Anyway I hope this will give you some help, maybe attach the section of your script that is not working right and I (we) can spot something that you are over looking.

To make a drop form a circular pattern around the unit (like a scattering dust/smok cloud after gound impact), for that you do need trig, but you must use it with the reference object direction as being 0 degrees regarless of what its map heading is (because drop is referenced to the object, not the map).

Offline Raptorsaurus

  • Editors Depot Staff
  • *****
Re:Executing an fx script on a game logic(complications)
« Reply #2 on: 11 Jan 2005, 04:07:02 »
It just occured to me that you may only have to set the game logic to the same direction at the plane:

_GL setDir (getDir _plane)

It is still strange that it works over water, but not land.

Offline Nemesis6

  • Members
  • *
Re:Executing an fx script on a game logic(complications)
« Reply #3 on: 11 Jan 2005, 08:14:57 »
What I mean about the facing one way thing was that it(the game logic) doesn't have a pitch. Yep - the thing that's causing me difficulty is the trigonometry. The positional array and the particle velocity are relative to the vehicle - they have to be if I am to use the cosine thing... or do they? I'm pretty sure they do...
I am actually flying into a star... this is incredible!

Offline General Barron

  • Former Staff
  • ****
  • Semper Fi!
Re:Executing an fx script on a game logic(complications)
« Reply #4 on: 12 Jan 2005, 20:38:31 »
The pitch of a unit shouldn't have any effect on the drop command, since the command only uses the position and direction the unit is facing.

Now, I'm sure we could help you out, but personally I have no idea what you are trying to do. There are a lot of ways that you can use that cosine "thing", so more info on what you are doing is required.  ;)
HANDSIGNALS COMMAND SYSTEM-- A realistic squad-control modification for OFP
kexp.org-- The best radio station in the world, right here at home! Listen to John Richards!

Offline Nemesis6

  • Members
  • *
Re:Executing an fx script on a game logic(complications)
« Reply #5 on: 14 Jan 2005, 22:42:02 »
Let me give you an example -

drop ["cl_fire", "", "Billboard", 1, 1, [0,0,0], [0,-3,1], 0, 1, 1, 0.001, [1,5], [1,1,1,1],[1,1,1,0],
, 0.1, 0.2, "", "", _heli]

Let's say the above is what I'm using. You know that _heli makes, say, the Z/up and down velocity relative to the vehicle, so if the particle is set to move upwards, the particle will fall downwards. Now, in my case, this would make the dust particles appear in positions that are relative to the vehicle... do you understand now? :)
I am actually flying into a star... this is incredible!