Home   Help Search Login Register  

Author Topic: dr eyeball dialog... script to pbo? (solved)  (Read 3595 times)

0 Members and 1 Guest are viewing this topic.

Offline loki72

  • Former Staff
  • ****
    • Loki's Nightmare
dr eyeball dialog... script to pbo? (solved)
« on: 11 Jun 2008, 08:15:09 »
greetings,


i've been trying to learn how to put this popup menu into pbo form.. i have had nothing but frustrations and i have yet to find some kind of tutorial on the subject...

plz.... somebody help!

thx
« Last Edit: 14 Jun 2008, 23:01:05 by loki72 »

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re: from script to pbo (edited)
« Reply #1 on: 12 Jun 2008, 10:58:19 »
Aye well, pop the stuff into a suitably named folder and use one of the pbo tools to PBO it, I use Eliteness.


EDIT:  I just looked at your file.
Is this an editor example mission or an addon?

Mission PBO's should be in the Missions folder whilst Addon PBO's would go in the Addon folder or a user Addon folder inside what is often called a mod folder.


Planck
« Last Edit: 12 Jun 2008, 11:05:41 by Planck »
I know a little about a lot, and a lot about a little.

Offline loki72

  • Former Staff
  • ****
    • Loki's Nightmare
Re: from script to pbo (edited)
« Reply #2 on: 12 Jun 2008, 13:44:03 »
greetings planck,

yes it is an example mission.. from dr. eyeball's dialog framework.. i have been using BinPBO Personal to create a pbo for testing... eliteness looks better.. think i'll use it from now on.

the problem is i don't know how to make a proper config.cpp file to reflect the calls needed to make the mission run in pbo form.

i figured i'd give the mission form, instead of my screwed to the max pbo form.. that i might get a clear understanding. and a working config.cpp :whistle:

SitRep:
when i make a config.cpp.. 1 of 2 things happen because the dialog #defines (and or) #includes aren't called right:

if i call the #includes from the description.ext from the config.cpp... i get gray bars at the main menu around all text...and when i load a map.. it CTD's..
or...
if i move the #includes.. further back and call them from a load.hpp.. i make it to the editor and in game.. but when i trigger it <T Key> i get an error about a missing ; in line 109 of the DialogControlClasses.hpp...and the dialog fails...

so.. by moving the #includes from one place to another.. causes me these errors.. it shows me i have no idea what's going on...and trial and error sux when one has to shutdown and restart arma to test if a  ;  is in the right spot... :blink:

i hope this helps.. let me know if you need more info.
« Last Edit: 12 Jun 2008, 15:12:15 by loki72 »

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re: from script to pbo (edited)
« Reply #3 on: 13 Jun 2008, 02:24:25 »
I'm sorry, I don't understand ... missions do not use config.cpp, I'm not sure what in fact you need a config in a mission for, maybe more explanation?


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

Offline loki72

  • Former Staff
  • ****
    • Loki's Nightmare
Re: from script to pbo (edited)
« Reply #4 on: 13 Jun 2008, 02:27:52 »
you are correct.. in mission no .cpp

but in all pbo's i have looked at.. there is no description.ext.. the #includes are always in some kind of a .cpp or .hpp file.

i guess the question is.. how do i take that dialog example and make it work in a stand alone pbo? i'm trying to make a better instant viewdistance addon.

edit: spoke with the good dr. it seems sickboy has found a work around.. but its all greek to me what he did..

Quote
A few comments about these dialogs.

While I was integrating these inside an Addon, I noticed you seem to have not just inherited from base classes like rscButton etc, but also overwritten values inside them, like colors etc. This is not a big problem when you run these dialogs from description.ext (Altough some other dialogs might expect other values), but when they are inside an addon, it will affect a lot of things :)
To get around this I changed all base classes to simply inherit from their originals: class rscButton;  etc. and some classes are setup so that we can inherit from their sub-classes, e.g:
class rscMap
{
 class Building;
 class Tree;
};
(etc, whatever)
I would suggest not overwriting values in the original classes but simply create your own: eye_rscMap: rscMap, eye_rscButton: rscButton etc classes in which you make the changes you need for your dialog template system :)

If im all wrong here or you have really valid reasons as to changing default values inside base classes, please excuse me :)

Edited by sickboy on Oct. 18 2007,08:57

http://www.flashpoint1985.com/cgi-bin/ikonboard311/ikonboard.cgi?s=9f3a8e3a7294057fb5e1c005c44e5a98;act=ST;f=71;t=62966;st=30;r=1;&#entry1257196
« Last Edit: 13 Jun 2008, 03:30:31 by loki72 »

Offline Dr Eyeball

  • Members
  • *
Re: dr eyeball dialog... script to pbo? (edited)
« Reply #5 on: 13 Jun 2008, 03:30:20 »
@Planck: It seems he is trying to include the dialogs & their classes in an addon.

@Loki72:
I have not attempted to put the dialog framework into an addon yet, so am not personally familiar with those issues. I use it primarily inside missions.
The problems are likely due to the class definitions in DialogControlClasses.hpp

Sickboy has already successfully added it to the 6thSense.eu Mod (see v1.03 update), so you may want to check what changes he made to achieve that.

Sickboy also posted in the BIS thread below of a similar problem that you describe.
He says because some of the base classes have their attributes changed, it affects the game when used inside a mod.

He worked around it by resetting the base classes to their original definitions, then deriving new sub-classes using the changed ones.
See Sickboy's post (Oct 18 2007, 16:56) in BIS forum: Dialog Template, plus Standard Dialogs

(This is a duplicate message of the PM I already sent Loki)

I'll check your posted file in the meantime, but the solution is likely to require a few days work, time which I don't have right now. 6thSense.eu mod is probably the way to go for a solution.

Edit: The posted file is just the original demo - it doesn't help diagnose the problem.
P.S. Once you get it working, there is an improved version of the framework contained in the Devastation mission. See the relevant images.
« Last Edit: 13 Jun 2008, 03:39:18 by Dr Eyeball »

Offline loki72

  • Former Staff
  • ****
    • Loki's Nightmare
Re: dr eyeball dialog... script to pbo? (edited)
« Reply #6 on: 13 Jun 2008, 03:38:11 »
thx for the reply dr. eyeball  :good:

as for the 6thSense.eu Mod (see v1.03 update)...

6thSense.eu Mod v1.24 (1GB, Windows NSIS Setup).

is this the one you mean?


Offline Dr Eyeball

  • Members
  • *
Re: dr eyeball dialog... script to pbo? (edited)
« Reply #7 on: 13 Jun 2008, 03:40:22 »
Yes, it would be v1.24 now.

Edit: Ok, it appears the code was added to 6thSense.eu mod under SIX_base.pbo using new folder names like: eyeball_common and eyeball.
I think his focus was mainly on using the popup menu dialog too.

I'm not entirely certain, but my understanding is that:
dialog classes like RscButton are undefined inside missions, which is why the framework needs to declare them,
but inside addons, the original dialog classes might already be accessible for use directly or simply need to be declared empty as an external reference.

See:
- cfgMod.hpp - for #include statements
- std.hpp - for the standard class declarations
- DialogControlClasses.hpp - cut-down/simplified version suitable for addon
« Last Edit: 13 Jun 2008, 06:04:32 by Dr Eyeball »

Offline loki72

  • Former Staff
  • ****
    • Loki's Nightmare
Re: dr eyeball dialog... script to pbo? (redux)
« Reply #8 on: 13 Jun 2008, 04:06:09 »
Quote
improved version of the framework contained in the Devastation mission

WOW!!!!  :clap:

i have a dedicated server.. this going on it now!

i will work with this one for a while... thx dr. eyeball

edit: thx.. i'm 36% of the 1.24 gig

redeux:

ok.. after 9 hours shifting through 1.24 gig for 4kb of code it is not going well...

made progress but with no forward progression...  :confused:

hopefully this will be fixed.. it is the best quick menu system i have seen yet.. but after 60 hours.. i am finished with it.  :dry:
« Last Edit: 13 Jun 2008, 13:00:14 by loki72 »

Offline Mandoble

  • Former Staff
  • ****
    • Grunt ONE and MandoMissile suite
Re: dr eyeball dialog... script to pbo? (redux)
« Reply #9 on: 14 Jun 2008, 10:12:14 »
Not sure if this has been already solved. If not, here is your addon working  :D

- Paths redone to match your addon name.
- Resource types renamed so they dont interfere with BIS default ones.
- Config completed.
- Original mission now uses your addon.

EDIT:
Loki_dlg folder is the addon folder.

Offline loki72

  • Former Staff
  • ****
    • Loki's Nightmare
Re: dr eyeball dialog... script to pbo? (redux)
« Reply #10 on: 14 Jun 2008, 23:00:50 »
mando.. i have no words to express my thanks... but THANK YOU!!!! :D

i had to put the init.sqf back in it... and added a line to the config.cpp so the popup would start...

one more donation to ofpec.. coming right up!!!

i will finish this and upload it to the addon beta testing.

WHOOT! :good:

here is the finished product:

http://www.armaholic.com/page.php?id=3365
« Last Edit: 17 Jun 2008, 06:04:18 by loki72 »