Home   Help Search Login Register  

Author Topic: Dialogs And Addons  (Read 2001 times)

0 Members and 1 Guest are viewing this topic.

Offline SilentHunter

  • Members
  • *
  • frozen leg'o'lamb (every gamers most loved weapon)
Dialogs And Addons
« on: 06 Mar 2005, 18:03:58 »
Im planning to populate a listbox with an array of addons, but it would be far easier if there was a set of commands that finds out what addons you've got

Question:
How can you make FP get a list off all the addons you've got in the addons folder?

I can work the rest out from there

SILENTHUNTER
[size=4.5]NERDS HAVE FEELINGS TOO! [/size] [size=2.5]*adjusts glasses*[/size]

Offline h-

  • OFPEC Site
  • Administrator
  • *****
  • Formerly HateR_Kint
    • OFPEC
Re:Dialogs And Addons
« Reply #1 on: 06 Mar 2005, 18:50:36 »
You can't...

Unless I completely misunderstood your question... ::)
Project MCAR   ---   Northern Fronts   ---   Emitter 3Ditor
INFORMATIVE THREAD TITLES PLEASE. "PLEASE HELP" IS NOT ONE..
Chuck Norris can divide by zero.

Acecool

  • Guest
Re:Dialogs And Addons
« Reply #2 on: 06 Mar 2005, 19:24:42 »
He wants to make a mission(?) that opens a dialog, and shows you all the addons you have installed in your flashpoint addons/ folder..

Offline SilentHunter

  • Members
  • *
  • frozen leg'o'lamb (every gamers most loved weapon)
Re:Dialogs And Addons
« Reply #3 on: 06 Mar 2005, 19:31:49 »
Bingo!
[size=4.5]NERDS HAVE FEELINGS TOO! [/size] [size=2.5]*adjusts glasses*[/size]

Offline h-

  • OFPEC Site
  • Administrator
  • *****
  • Formerly HateR_Kint
    • OFPEC
Re:Dialogs And Addons
« Reply #4 on: 06 Mar 2005, 19:36:12 »
So I understood it correctly then... :P

And you can't do that (afaik)...
Project MCAR   ---   Northern Fronts   ---   Emitter 3Ditor
INFORMATIVE THREAD TITLES PLEASE. "PLEASE HELP" IS NOT ONE..
Chuck Norris can divide by zero.

scooter24

  • Guest
Re:Dialogs And Addons
« Reply #5 on: 06 Mar 2005, 20:34:06 »
Hey!
I have to disagree. I think it is possible. Using a program such as flash, you could create 3 folders: Official Addons, Unofficial Addons and Wrong Format addons. This sounds like a great idea! Alls you'd need to do is to get the database to search your addons folder and sort the files out.
Scooter24.

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re:Dialogs And Addons
« Reply #6 on: 06 Mar 2005, 21:47:33 »
Emmmm.......I think he wants to do this from within his mission, so I have to concur that it isn't really possible.

AFAIK there is no command that allows you to run external programs or files from within the game.


Planck
I know a little about a lot, and a lot about a little.

Offline SilentHunter

  • Members
  • *
  • frozen leg'o'lamb (every gamers most loved weapon)
Re:Dialogs And Addons
« Reply #7 on: 07 Mar 2005, 17:36:48 »
*Reaches for frozen leg of lamb*
[size=4.5]NERDS HAVE FEELINGS TOO! [/size] [size=2.5]*adjusts glasses*[/size]

Offline Platoon Patton

  • Members
  • *
  • "Barbecue" CreateVehicle getpos LLama
Re:Dialogs And Addons
« Reply #8 on: 07 Mar 2005, 18:56:21 »
He wants to make a mission(?) that opens a dialog, and shows you all the addons you have installed in your flashpoint addons/ folder..

The only thing U know is that all the required addons for this missions are in an addonfolder.
Otherwise U would get an error.

So,is there a way to get the info from mission.sqm (addOns[])?

This array must be stored somewhere,as it shows up in Flashpoint.rpt when OFP chrashes..
« Last Edit: 07 Mar 2005, 20:38:08 by Platoon Patton »
http://www.platoon-clan.com/ We always wellcome dedicated OFP players :)

http://www.european-combat-league.com/index.php To play with us in the best OFP league ;)

bored_onion

  • Guest
Re:Dialogs And Addons
« Reply #9 on: 07 Mar 2005, 19:44:35 »
um... maybe you could do this is in a very long and tedious script using the "typeOf" command. get the script to identify every object in the mission which is an not original by checking it against everyone which you know is standard BIS unit. then you could use the typeOf command to create a sting with its type and then you could stick it in the listbox. it does assume that every addon available is on the map, though.  :(

something like this:

Code: [Select]
_type=typeOf _unit

? !_type=BIS UNIT 1 AND !_type=BIS UNIT 2 OR ... (you get the idea):goto "DisplayAddonName"

exit
 
#DisplayNewAddonName

*command to update dialog with the variable '_type'*

and there's a very long way around it... unless ive got something wrong... in which case its not :-\

Offline SilentHunter

  • Members
  • *
  • frozen leg'o'lamb (every gamers most loved weapon)
Re:Dialogs And Addons
« Reply #10 on: 07 Mar 2005, 20:34:22 »
What if we edit some vital game system files to make the ENTIRE mission.sqm a public variable, (u 'ered, ENTIRE). It would work in the same way the game updates the time in hex and converts it to a sqs compatable command in the form of the variable _time (surprisingly)

What ya think?

[size=4.5]NERDS HAVE FEELINGS TOO! [/size] [size=2.5]*adjusts glasses*[/size]

Offline h-

  • OFPEC Site
  • Administrator
  • *****
  • Formerly HateR_Kint
    • OFPEC
Re:Dialogs And Addons
« Reply #11 on: 07 Mar 2005, 23:45:55 »
Quote
What ya think?
It would be illegal...
You would need to distribute a 're-engineered' game file, and the 're-engineering' is already illegal, so...

Furthermore, how exactly you would utilise a 'public variable' of that lenght (in 'worst' cases hundreds (even thousands) of lines long..)??
You still could not search the variable with OFP functions and/or pick any part from it etc...
So it would not solve your 'problem' at all...

And, why it is so important to know what AddOns someone has?? If your mission or something would require hacking OFP game files then you need to seriously re-think your approach...


You could try a variation of bored_onion's idea, and list all the AddOns you know, camCreate or createVehicle them and check if there's something created, and if there is you would know which AddOn is used...

harsh example:
Code: [Select]
_veh = "somevehicle" camCreate [0,0,0]
? isNull _veh: thisAddOnInUse=false
Project MCAR   ---   Northern Fronts   ---   Emitter 3Ditor
INFORMATIVE THREAD TITLES PLEASE. "PLEASE HELP" IS NOT ONE..
Chuck Norris can divide by zero.

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re:Dialogs And Addons
« Reply #12 on: 08 Mar 2005, 00:03:19 »
I think what he wants to do is use a dialog that has a listbox, which will list all the addons that are in the addons folder on the machine it is running on.

He is looking for a way to interrogate the addons folder and get a list of the addons to put in the listbox.

I don't see a way to do it from within OFP.


Planck
« Last Edit: 08 Mar 2005, 00:03:53 by Planck »
I know a little about a lot, and a lot about a little.

Offline SilentHunter

  • Members
  • *
  • frozen leg'o'lamb (every gamers most loved weapon)
Re:Dialogs And Addons
« Reply #13 on: 08 Mar 2005, 00:47:45 »
@Hater_kint

@prospect of it being illegal,
what is this term "illegal" you speak off, (I jest (joke))

Quote
You could try a variation of bored_onion's idea, and list all the AddOns you know
Too easy

Quote
You still could not search the variable with OFP functions
(hmmmmm, the man raises a good point here, struggles to thing of defensive comeback) I suppose I would have to edit the game to do that aswell. In fact while im at it I might as well write a COMPLETELY new game, shouldn't take me too long…

Quote
And, why it is so important to know what AddOns someone has?? If your mission or something would require hacking OFP game files then you need to seriously re-think your approach...
In all my many years of flashpointing, across many boards on many servers I have never seen an idea met with such criticism by a single person. Why must you mock and I idea or principle you know little about? My motive and methods haven't even been revealed. I could do the coding in hex myself. (@ other hex crackers while im on the subject, flashpoint is written really poorly inside aint it, it's a miracle it works at all!)

For shame to all of you, FOR SHAME, *turns back on flashpoint, goes plays counter strike, gives in after 3 mins, goes back to flashpoint*

SILENTHUNTER

"Writes suicide note" : for shame

*hangs self*
[size=4.5]NERDS HAVE FEELINGS TOO! [/size] [size=2.5]*adjusts glasses*[/size]

Offline h-

  • OFPEC Site
  • Administrator
  • *****
  • Formerly HateR_Kint
    • OFPEC
Re:Dialogs And Addons
« Reply #14 on: 08 Mar 2005, 09:39:11 »
Quote
In all my many years of flashpointing, across many boards on many servers I have never seen an idea met with such criticism by a single person.
Then you must not have been at BI Forums at all... Ever... ;D ::)

Quote
Why must you mock and I idea or principle you know little about? My motive and methods haven't even been revealed.
Well, why don't you reveal something about your motives then...

Because I just can't see why to go through all that 'trouble' just to get some addon list...
I'm not mocking anything, I'm just assuming (due to you not revealing much about your motives) that this again something that could be done much easier than hacking the game...

But I'm not stopping you...
I doubt that many would use something that alteres the original game though...


I think if this hacking discussion is continued any further this topic's getting locked quite soon....
« Last Edit: 08 Mar 2005, 09:43:13 by HateR_Kint »
Project MCAR   ---   Northern Fronts   ---   Emitter 3Ditor
INFORMATIVE THREAD TITLES PLEASE. "PLEASE HELP" IS NOT ONE..
Chuck Norris can divide by zero.