Jump to content
Sign in to follow this  
Tychon

Ofp dialog editor

Recommended Posts

Alright, I suppose the name is misleading, as the program does not in fact edit dialogs per se. At the moment, all it really does is dump the position, size, and colors of rectangles drawn, in OFP number format. Which is to say, 0 to 1, and any amount in between.

 I created this program due to the simple aggravation of constantly flipping between OFP and notepad, constantly tweaking sizes and such of my dialogs, as I'm sure those of you reading this understand. - excerpt from readme.txt

 After about 5 hours of coding, I feel that this program has at least reached a point where it can be unleashed upon the masses, heh. I've attempted to create it as bug free as possible, of course, but the enviroment it was created in is fairly new to me. So please, if you see any bugs in the program, or in the numbers it dumps, please let me know. I only tested the actual dumps a couple times, as I need to get on about my day.

 Anyways, I just hope someone at least finds a use for this. It seemed like a good idea to me at the time... confused.gif

(I also apologize if this should have gone in a different forum, being as it deals with dialogs I just felt ME was the right one.)

ofpde.zip

Share this post


Link to post
Share on other sites

Great work, I will give this a test tonight.

RED

Share this post


Link to post
Share on other sites

Bump, alot of people have asked for a tool like this. It could do with some more features though.

RED

Share this post


Link to post
Share on other sites

Paste the link into your adress bar, it is hosted on tripod.

RED

Share this post


Link to post
Share on other sites

Cool.

This'd be really useful if you could get in most, if not all, of the features. wow.gif

Please keep at it. smile.gif

Gameer

Share this post


Link to post
Share on other sites

Ok, perhaps I'm just oblivious, but what features specifically are being requested? I have several ideas of features to add, but I'd like to know what people would want available, and I'll try to add it in. Well, due to the poor modability of the current code, I'm going to tear it down and build it back up again, hopefully with a much better design. And hopefully with some features requested. biggrin.gif

Share this post


Link to post
Share on other sites

Very cool...hmmm..ill try and think of some features lol..

um...maybe copy, paste, and delete?

undo and redo?

um... being able to type in specific sized boxes?

very good job! i wish i had this when i was creating my huge dialog of around 40+ buttons and read outs

i really wish i could do some programing to be able to do these things....anyways...keep up the good work! biggrin.gif

Share this post


Link to post
Share on other sites

Slider, Buttons, ActiveTexts, Static Text, Edit (text) Box, Drop-Down boxes and List-Boxes.

Basically, everything. tounge.gif

And maybe you could make it so it add's everything, like all the declarations and so on which has to be done before.

Hope you can manage it tounge.gifbiggrin.gif

Just Kidding, although all this would be good smile.gif

Keep it Up

Gameer

Share this post


Link to post
Share on other sites

Alright, just a little news update. Perhaps pointless, but ah well.

 Yes, I am working on the second release of OFPDE, but due to the features I want added in before I do release it, it may be awhile before it crawls out amongst the masses. I have no idea when it will be finished, or what features will make it into the release. However, I do have a little list of overall features that I intend to implement in OFPDE - the more asthetic things, such as on-the-fly syntax highlighting, have a lower priority than say, dynamically drawing a dialog from an EXT file.

 However, there are two approaches I have before me. I can code it to either have dialogs drawn, then write the results of the drawing into a workable EXT file, or, only display a dialog based on an EXT. The ability to draw would make the process faster for the user, but the end result would probably be a more simplified creation process, with less actual control. Depending solely on the user writing up an EXT however means more work based on the user.

 Although, I could implement both methods - which would add on time before the next release, of course. Ultimately I will code in both, as they're both desirable methods, however, what should I code right now? I like to base the product entirely on user demand, so before I really get into the foundation of it, I would like to know.

 At any rate, here's a little list of features I want to implement into OFPDE. As to what release any of these features will be in, not a clue. They're just things I want in there at some point.

  -> Dialog syntax checker

  -> On-the-fly syntax highlighting

  -> Templates (I.E., predefinitions that will be written to all dialogs)

  -> Alpha "color" channel

  -> Actual dialog representation (Displays pictures that a dialog displays, etc.)

 Well, they're just things I want to add in. We'll see at any rate. Anyways, if you have anything not listed there, that you'd like to see in the program, please post it here, and I'll take it into consideration. But please consider the feasibility - example, functioning dialogs, which will in fact function based on OFP script code, to a degree. While nice, creating a dialog with buttons that can actually be clicked, and sliders that will slide, inside this program, would be moreso asthetic than a necessity, and would more or less be a pain to code. While I'm not saying such will never happen, it would definitely be a low priority consideration.

 At any rate, that's that. Hopefully, and this is a very vague estimation, I will have v0.10 out by sometime next week. But this is very vague, and can go up in smoke at any time, but I'll try anyways.

Addendum:

 For those of you who care, here's the current look of the next release. It's just a shot of the editor, but just figured some of you might like to see. I apologize for the terrible quality of the pic, I converted it so it would be easier on the 56Kers. And yes, the code in the editor is a direct copy from Vektorbosen's dialog tutorial, much thanks to his work for me learning dialogs. And the color is due to it being a direct copy, I haven't yet finished syntax highlighting. tounge.gif

ofpde_ss.txt

Share this post


Link to post
Share on other sites

</span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote (Tychon @ Mar. 18 2003,17:27)</td></tr><tr><td id="QUOTE">Well, they're just things I want to add in. We'll see at any rate. Anyways, if you have anything not listed there, that you'd like to see in the program, please post it here, and I'll take it into consideration. But please consider the feasibility - example, functioning dialogs, which will in fact function based on OFP script code, to a degree. While nice, creating a dialog with buttons that can actually be clicked, and sliders that will slide, inside this program, would be moreso asthetic than a necessity, and would more or less be a pain to code. While I'm not saying such will never happen, it would definitely be a low priority consideration.<span id='postcolor'>

There's no need to make the dialogs actually work (IE. Click, or move.

Just so you can create little boxes for the buttons, for example.

And it looks good so far, looking forward to it. smile.gif

Gameer

Share this post


Link to post
Share on other sites

Geez i wish i hadn't been required to only take Fortran90 coding in college.... Very nice work Tychon....

Just a little thought.... maybe for the action buttons it could give a prompt to enter in the action(s) for that button

Great job....whew :: whipping tears out of eyes:::

Share this post


Link to post
Share on other sites

Ah you mean so you don't have to code it in the EXT? Yeah, I could manage that.

And the example up there was just an unfeasible example, Gameer. I mean it would be interesting to add in, but if that ever does happen it'll be when all major features are already set in stone and whatnot, heh.

Share this post


Link to post
Share on other sites

</span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote </td></tr><tr><td id="QUOTE">Alright, just a little news update. Perhaps pointless, but ah well.<span id='postcolor'>

Absolutely not pointless  smile.gif, thanks alot. I only just discovered your little gem. This is exactly what I just waited for.

As you asked for any wishes, here they come  biggrin.gif :

As Gameer said, I think it is not necessary to make the dialog objects functional. It would be nice if one can assign a name to an object (perhaps the .ext class name) that is displayed within the rectangle.

To create nicely aligned buttons, a snap-to-grid feature would be great.

Thanks again,

Spinor

Share this post


Link to post
Share on other sites

Heh, don't worry about that, the naming of controls and such will be in the next release, what's currently out is just something I slapped together in 5 hours, heh. As to a snap to grid, I'll have to look at that. I first want to get the core stuff done, but I'll try and add it in - dunno if it'll make next release or not though, we'll see.

Share this post


Link to post
Share on other sites

Good news! Things are going better than expected. So much better in fact, it is possible that an early edition of the next release may be out by Saturday, possibly even Friday. It will only be the basics though, nothing fancy. But you will be at least able to paint objects, move them about, and have them dynamically added into your EXT file.

 And remember, I said it's possible, I didn't say it was guaranteed. tounge.gif

Share this post


Link to post
Share on other sites

Well, I have some decently surprising news, to me anyways. The core of version 0.10 is complete, so this means, it's up and available for download. All the features I want in this version aren't there yet, but the core stuff is done, and it works, so I'm going to release it now.

OFPDE.zip

 As per usual, if anyone sees any bugs, please post them here, telling me what you did, what it said or did, et cetra. Since I was too lazy to write another readme file, I'll just type up a quick thing on how to use it here.

 To start, click on File -> New EXT. This will either load up your template file or will simply add the controls index to the editor. On a quick tangent, if you place a file named template.txt in the same directory as OFPDE, anything inside it will be loaded into the editor when you click on New EXT. You will have to manually add in your own controls index, but that's simple. Simply add the following two lines, exactly as is, with no spaces before them, into the template file where you want the control code to be added.

</span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE">

// Controls

// ~Controls

<span id='postcolor'>

 And again, there must be absolutely NO spaces before the index, or else you'll get an unable to find controls index error.

 Drawing is exactly the same as the previous version, so I won't go into it. However, when you finish drawing, a dialog box will pop up asking for three things. You only need to enter the control type, such as RscText, or RscActiveText, whatever you have defined. I think you all can figure out what control name is for, and control action is whatever the action for the control is. Neither of these two need be entered however. When this is done, it will add in the basic code for the control into the editor. Special type-based control statements won't be added, but that's all you will have to type at least.

 By now you may have noticed the menu called Dialog. There are two working options up there. Insert mode and edit mode. Insert mode is the default mode, which allows you to draw controls. Edit mode allows you to move and delete controls. Left click and drag to move a control, right click to delete it.

 Well, that's about all of it. Save simply saves to description.ext in the directory of the program, load opens up the EXT. Hope this helps you all. I know, it's fairly low on features even still, but I'm working on it. biggrin.gif

Addendum:

 Fixed a couple tiny bugs, and added in it showing the names of the controls as hints. There you go, Spinor. tounge.gif Still need to look at the snap-to-grid idea though.

Share this post


Link to post
Share on other sites

Good work, I will give this a go tonight.

RED

Share this post


Link to post
Share on other sites

Great smile.gif , especially the drag'n'drop feature is very nice. I only tested your todays first version yet, looking forward to the named boxes.

I only noticed two bugs:

- In your output, I think you export the numbers with commas 0,1343 rather than dots.

- Missing snap-to-grid feature tounge.gif

One other suggestion: What about displaying the dimensions of a control (x,y,h,w) in the popup menu?

If you make them editable, one could fine adjust them by hand (if one wishes). This could be useful for placing, say, buttons with fixed sizes h,w.

Great work!

Spinor

Share this post


Link to post
Share on other sites

Okay, could someone explain exactly what this does? It says text editor, yet it isn't, and reading over the readme excerpt... I still dunno what it does...

Share this post


Link to post
Share on other sites

Er, text editor? No, it's a dialog editor.. it's for visually constructing dialogs for OFP: Resistance.

As to the commas, does it output commas on all X, Y, W, and H properties? It's putting periods on my end, hm.. and as to the manual adjusting of properties, I am going to add that in, but as I said, this was just a release of the core features - I.E., ultimate basics, heh. Don't worry, that will be in there shortly though - I was just wanting to get something out so the first release would fade from memory. Gah that thing was hideous. But if you'll notice in the Dialog menu, a grayed out selection titled, 'Update Display'. That will be what you click to update sizes and positions for manual editting. Just felt you might like to know, hehe.

Oh, and just redownload the .zip file, I already added in the named boxes. I always use the same link, so you can just download it every now and then. I won't post every fix, as at this point that may get spammy as I come across little bugs and such.

Share this post


Link to post
Share on other sites

</span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote </td></tr><tr><td id="QUOTE">As to the commas, does it output commas on all X, Y, W, and H properties? It's putting periods on my end, hm.. <span id='postcolor'>

Will have to check again (I'm not at home right now). Maybe it has something to do with Windows language settings? I am using German, and I think the default is ',' for numbers.

</span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote </td></tr><tr><td id="QUOTE">. and as to the manual adjusting of properties, I am going to add that in, but as I said, this was just a release of the core features - I.E., ultimate basics, heh.<span id='postcolor'>

No need to hurry (in fact no need to implement it at all if you think it unessesary). I'm just dumping out ideas and wishes.

</span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote </td></tr><tr><td id="QUOTE">Oh, and just redownload the .zip file, I already added in the named boxes.<span id='postcolor'>

Yup, I gathered that. Its just that your program probably won't run on the university Linux machine I am sitting in front of right now wink.gif .

Share this post


Link to post
Share on other sites

Ah yes, language settings would do that to you. Hehe.

And I'm definitely adding it in, that's too necessary a feature to consider leaving out. Eventually I hope to add in a sort of debugging tool to error check one's code and whatnot, but that will probably be awhile before that comes around, heh.

And no, while I could have worked it to be cross-platform compatible, I saw little point. OFP being a Windows game, I just didn't think it worth the effort tackling that beast, hah.

Share this post


Link to post
Share on other sites

</span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote </td></tr><tr><td id="QUOTE">And no, while I could have worked it to be cross-platform compatible, I saw little point.<span id='postcolor'>

That was a good decision. Otherwise I would be designing dialogs at university which would be detrimental to my studies biggrin.gif .

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×