Search

Last Downloaded

zip-0 Microsoft Sidewinder
zip-1Starmap Reference Guide

Login

calling a .dll function?

MajorTom's Avatar Topic Author
Junkie Junkie
  • Posts: 992
  • Thanks: 0

calling a .dll function?

21 years 5 months ago
#18145
Maybe that's the wrong terminology but there must be some way to call a native package or virtually "press" a key for the player?

Is there any way to call a function like:
"icDirector.InternalCamera" or "icDirector.ExternalCamera" directly with pog?

Why? If you create a brief external view of a ship with iDirector it's stopped dead in it's tracks. (because iDirector suspends/purges the input keybinds). As a result you have to reapply throttle to get the ship moving again. [V]

You can intercept the keybind for the camera package, to get an external view, without stopping the ship, but you can't get it back to the internal view (Hud) without pressing the (F1) key manually.

I've tried Task.Call and Task.Detach with the camera function as a string but flux seems to just ignore that [?]




Iwar2 Multiplayer Fan Site

Please Log in or Create an account to join the conversation.

GrandpaTrout's Avatar
King of Space King of Space
  • Posts: 1135
  • Thanks: 0

Re:

21 years 5 months ago
#10679
I have never done it. I do expect it is possible, because the libraries do it all the time. It might just be a case of figuring out how to tell the pog compiler - now setup the calling stack for a real C++ call, and not a script call. The library header files do have special compiler flags in them. What I don't know - does the recieving DLL need to be specially prepared somehow to take this call? I would think not. too much work. I am guessing anything can be called. But if that called thing was not designed to be called from POG - crash.

It is worth looking into. I have a little free time tomorrow. I wonder what the microsoft debugger has to say about the calling stack....

-Gtrout

Please Log in or Create an account to join the conversation.

MajorTom's Avatar Topic Author
Junkie Junkie
  • Posts: 992
  • Thanks: 0

Re:

21 years 5 months ago
#10689
Originally posted by GrandpaTrout



It is worth looking into. I have a little free time tomorrow. I wonder what the microsoft debugger has to say about the calling stack....

-Gtrout

That would be really cool :D

Iwar2 Multiplayer Fan Site

Please Log in or Create an account to join the conversation.

GrandpaTrout's Avatar
King of Space King of Space
  • Posts: 1135
  • Thanks: 0

Re:

21 years 5 months ago
#10720
No luck. What I think is happening is this: When they want to call into a DLL from POG they declared a "Flux Extension" and this tells the POG interpreter - when you see a call by this name, don't go look for a POG package, instead, call over to this DLL. Which makes sense, but it does not leave us with a way to extend the DLL calls without recompiling FLUX.

My strongest reason for believing this is that I can find no difference in the header files (from a POG viewpoint) that would tell the POG compiler, hey, handle this special. Reading the header files again, it is clear the special behavior is on the C++ side. And, if I examine the binary files, I can find the names of the flux calls. So, again, I think the name matching is done in C++.

Which leaves us nowhere as far as getting a keypress activated from POG.

-Gtrout

Please Log in or Create an account to join the conversation.

MajorTom's Avatar Topic Author
Junkie Junkie
  • Posts: 992
  • Thanks: 0

Re:

21 years 5 months ago
#10726
Thanks for trying [8D]

Iwar2 Multiplayer Fan Site

Please Log in or Create an account to join the conversation.

Second Chance's Avatar
King of Space King of Space
  • Posts: 1152
  • Thanks: 0

Re:

21 years 5 months ago
#10799
I don't think PS ever intended EoC to be quite that moddable. Which is a shame, because it would mean we could've possibly replaced the physics engine used with one that has a different flight model. Oh well, maybe one day they'll release the source.

mailto:second_chance@cox.net
The Ultimate Guide To Modding: I-War 2 - Edge Of Chaos (on hold during SW MP mod)
cartoons.sev.com.au/index.php?catid=4
.

Please Log in or Create an account to join the conversation.