HeroEngine Forums
Welcome, Guest. Please login or Register for HeroCloud Account.

Author Topic: [Resolved] Custom Spec Editor  (Read 1857 times)

webside80

  • General Accounts
  • *
  • Posts: 9
    • View Profile
[Resolved] Custom Spec Editor
« on: May 08, 12, 10:32:24 AM »

HI, I've managed to get my Spec Oracle class working, and also Spec Decorators, now i'm looking at creating a custom interface.

I'd like the interface to have an ordered list of fields (as the default one has them randomly listed), or a completely new interface that has the fields positioned in a more graphically pleasing format (less row like).

I know I shouldn't jump in at the deep end - so being able to order the fields, and maybe insert sections/breaks into the GUI would be preferable.

I am not sure where to start - do I create an XML that inherits from the default editor? If so how to I override it to order the list and insert sections and breaks.

Thanks in advance,

Webside80.
« Last Edit: Oct 31, 12, 02:59:38 PM by HE-Cooper »
Logged

Legacy

  • General Accounts
  • *
  • Posts: 117
    • View Profile
Re: Custom Spec Editor
« Reply #1 on: May 08, 12, 11:37:32 AM »

It is indeed possible. Just look at this page: http://hewiki.heroengine.com/wiki/Spec_editor that should get you started. The Fx editor is an example of highly customized spec editor so I'd study how that one works too..

Hope this helps
Logged

webside80

  • General Accounts
  • *
  • Posts: 9
    • View Profile
Re: Custom Spec Editor
« Reply #2 on: May 08, 12, 12:58:46 PM »

Thanks for your reply. I had been reading the page you mentioned, but it doesn't really explain how you layout the custom GUI, rather how to create custom controls.

I did look at the FX editor, guess I'll have to take a deeper look into it.
Logged

Chromehound

  • General Accounts
  • *
  • Posts: 151
    • View Profile
Re: Custom Spec Editor
« Reply #3 on: May 08, 12, 01:26:39 PM »

You could try here http://hewiki.heroengine.com/wiki/Hotspot

There's a section "Example: Modifying the Utilities Interface for the first time".  Make sure you follow that and make it game specific so you have the default stuff to fall back on.

After that, it's just a matter of editing the .xml to do whatever you want.
Logged

Legacy

  • General Accounts
  • *
  • Posts: 117
    • View Profile
Re: Custom Spec Editor
« Reply #4 on: May 08, 12, 01:37:21 PM »

Thanks for your reply. I had been reading the page you mentioned, but it doesn't really explain how you layout the custom GUI, rather how to create custom controls.

I did look at the FX editor, guess I'll have to take a deeper look into it.

Well at the very bottom of the page is a section on creating whole custom editor which is what you need. There you can find how to start. The way of displaying the rows is just a matter of procedural GUI work. Look at default editor to see how it works.

If you are looking for completely random interface you will have to create it manually via GUIXML and fill values by hand. The default system, while not visually so plausible is however able to make you edit almost anything without the need to create anything manually, if you are just starting your production, I'd recommend leaving this for later, because maybe you will discover this is way too much work to bother with in the first place. But it all depends on what you are trying to achieve...
Logged

TGSRofar

  • General Accounts
  • *
  • Posts: 153
    • View Profile
Re: Custom Spec Editor
« Reply #5 on: May 08, 12, 04:55:36 PM »

If you want to create a custom spec editor, there is no need to follow anything like the standard spec editors.  You can just build a completely custom GUI window, make all your controls, create a class for it and script the functionality.  Just need to make sure the spec to be edited gets sent to your editor and you send the modified spec to the server to be saved.
Logged
Ron Farrell
Lead Programmer
Triad Game Studios

webside80

  • General Accounts
  • *
  • Posts: 9
    • View Profile
Re: Custom Spec Editor
« Reply #6 on: May 09, 12, 06:54:15 AM »

Thanks, everything is slowly falling into place (in my head).

I've got a custom GUI showing the spec values, now to work out how to save to server. I've found the "shopSpecEditor" on the HJRef server of great help, if anyone else is having the same troubles as me.
Logged