Well-Actually War Trall Ishad Nha Posted April 3, 2009 Share Posted April 3, 2009 I think that I have carbonized the Windows PC Editor, see http://www.freewebs.com/ishadnha/BoEPCEditor2009.zip The use of custom items will still require hex-editing the list into the compiled program. I have not yet resolved this problem, I may be able to borrow code from the Scenario Editor. All items given by the I1 thru I10 menus are identified when they are received by the relevant PC. Resources necessary for compiling the source code are also included. There is also a pre-existing issue with the main status (alive, dead, stoned&) of the various pcs being all mixed up together. Edit: To make the above link actually work, you will need to click it, make the address bar active and then press Enter. Edit: If the above link does work when you click on it, you don't need to worry about the instructions above. Quote Link to comment Share on other sites More sharing options...
Well-Actually War Trall Niemand Posted April 3, 2009 Share Posted April 3, 2009 Perhaps I'm mistaken, but I had always understood the meaning of 'carbonize', with regard to software, to mean converting old macintosh application code to use the newer Carbon libraries. Since, to the best of my knowledge, the phrase is meaningless for Windows software, i assume that you have gotten it up and running. Quote: The use of custom items will still require hex-editing the list into the compiled program. This sounds familiar, as I routinely make deposits at the bank by circumventing the alarms, drilling into the vault, and putting my money inside. More seriously, I was able to add this feature to the Mac version of the program pretty easily. Looking at load_scen_item_defs() and its usage in ed.fileio.c of the Mac source code should give you the gist of it, although the code itself isn't portable, as it heavily uses the OS X Core Foundation and File Manager APIs. EDIT: As always, I'm baffled by how you get your site to screw up incoming links. Just so you know, I simply instructed my browser to download the file the link points to, and it worked fine. Directing people to do so might me easier than your current, somewhat confusing, instructions. Quote Link to comment Share on other sites More sharing options...
Well-Actually War Trall Ishad Nha Posted April 3, 2009 Author Share Posted April 3, 2009 I can't really program but I can hex-edit...My approach would only take a minute or two at most. I will have to look at your code at some point. The altered Itemdata.h was rapidly whipped up using Excel and then Word, the data originally came from bladbase.exs. Links, I am using Internet Explorer, maybe that is it. Other notes: The Editor now lists all items including items that work differently, like food and money. Clicking on such an item will increase your food and money, it won't add anything to the inventory. I will need to include an information screen that shows gold, food, day, location and whether the party is in town. "There is also a pre-existing issue with the main status (alive, dead, stoned&) of the various pcs being all mixed up together." There is a problem with a dead PC messing up the status listings for all PCs, Solution seemed to be adding “ if (i == current_active_pc) { ” to the start of each case in the switch (adven.main_status). Of course a corresponding } has to be added at the end of each case. Edit: I thought Carbonize meant customize, anyway... Quote Link to comment Share on other sites More sharing options...
Well-Actually War Trall Ishad Nha Posted April 4, 2009 Author Share Posted April 4, 2009 Quick fix, hex editing custom items into a Windows Character Editor. This will have to do until I can get the hang of opening files in the editor, which will take a while because I am working on four or five projects at once. Open the scenario file in Hexplorer or some such hex editor. Open the Character Editor in another copy of Hexplorer. Make sure the copy of Hexplorer showing the Editor is set to Overwrite not Insert. In the scenario the item data structures are found at address hex A3D6 = 41,942. It is 26,400 bytes in length. Select this and choose Edit > Copy As > Hex string. Start of the item data structure in the current version of the editor: 1,9A00 = 104,960. This time choose: Edit > Paste external text > As hex numbers. If you want to edit the editor so as to spell out which scenario has its items listed, the text displayed in the Title bar is found at: 2,0E00 = 134,656. Copying is no problem, I delete everything before place 41,942 then go to place 26,399 and choose Shift + Home. After doing the Copy As > Hex string, I do File > Reload to remove all the deletions. Quote Link to comment Share on other sites More sharing options...
Understated Ur-Drakon Celtic Minstrel Posted April 14, 2009 Share Posted April 14, 2009 So, if I understand this right... you haven't actually fixed any bugs in the character editor yet? Quote Link to comment Share on other sites More sharing options...
Well-Actually War Trall Ishad Nha Posted April 14, 2009 Author Share Posted April 14, 2009 Any errors in the original Itemdata.h have been fixed by replacing this with the data from Bladbase.exs. That is about it. I also removed irrelevant material from the game dialog file. Apart from that there have been no alterations by me. Quote Link to comment Share on other sites More sharing options...
Rotghroth Rhapsody Chokboyz Posted April 17, 2009 Share Posted April 17, 2009 Ishad Nha, I've continued your work on the char editor. Here are the changes i implemented, following your suggestions: The editor now display the filename of the scenario you are in. The editor now get the list of items from the scenario you're in. If not in a scenario, bladbase.exs is used. (clicking a item with food (resp. gold) type will give a random (1-20) amount of food (resp. gold).) References to registration and shareware are removed. Status Screen now show Food, Gold and Day. Corrected the garbled status due to a non-alive character (Ishad Nha) The code can be found in the openexile repository on Google Code (sorry about the two blank revisions, but i was trying a GUI and it automatically committed the changes. Nothing like the command line, hey ) since i think this part of the code is pretty complete (ressources files should be cleaned though, lots of useless dialogs i think). Note that the editor tries to find the scenario files under your scenario folder (the joke of changing the current directory has been fixed here too) and bladbase.exs under your blade of exile directory (this is where it should be, right ?). Hope it helps, Chokboyz Quote Link to comment Share on other sites More sharing options...
Well-Actually War Trall Ishad Nha Posted April 18, 2009 Author Share Posted April 18, 2009 Good, long overdue. If the repository is: http://code.google.com/p/openexile/ currently the only thing available for download seems to be the OSX BoE game. Quote Link to comment Share on other sites More sharing options...
Rotghroth Rhapsody Chokboyz Posted April 18, 2009 Share Posted April 18, 2009 Odd, i added a Win32 folder in the trunk folder ... Look here http://code.google.com/p/openexile/source/browse/ under the trunk directory ... I see the files. If you don't, i may have done something wrong Chokboyz Quote Link to comment Share on other sites More sharing options...
Well-Actually War Trall Ishad Nha Posted April 18, 2009 Author Share Posted April 18, 2009 I can see the files, I will have to download them at some time, I have a cold today. Quote Link to comment Share on other sites More sharing options...
Rotghroth Rhapsody Chokboyz Posted April 18, 2009 Share Posted April 18, 2009 Quote: I have a cold today. Rest well, then Chokboyz Quote Link to comment Share on other sites More sharing options...
Well-Actually War Trall Niemand Posted April 18, 2009 Share Posted April 18, 2009 I was looking into what would be necessary to add Chokboyz's improvements to the Windows Character editor to the Mac version that I had been maintaining, but from my examination of the code in your repository, it looks like you've already subsumed my code. If that's the case, I'll take down my page and let you guys handle things. I was never really interested in being in the BoE business anyway, I just got the character editor up and running because there had been so much whining about it. Quote Link to comment Share on other sites More sharing options...
Understated Ur-Drakon Celtic Minstrel Posted April 18, 2009 Share Posted April 18, 2009 Oh... I guess I'll have to do an svnmerge when I commit my next revision... I guess I'll also need to add the improvements you added at some point. Hopefully I won't forget. You may poke me if I do. Quote Link to comment Share on other sites More sharing options...
Rotghroth Rhapsody Chokboyz Posted April 18, 2009 Share Posted April 18, 2009 Quote: I was looking into what would be necessary to add Chokboyz's improvements to the Windows Character editor to the Mac version that I had been maintaining, but from my examination of the code in your repository, it looks like you've already subsumed my code. I couldn't find the BoE editor on your website, thus i don't know what changes you've made. The only change i could find was in the news : you added a save as option (i won't add it for now : save should always be save as, as the Win32 char editor is still beta). I will gladly add to the Win32 Char Editor any further addition you've made and provide pieces of code missing from the Mac version (unfortunately, changes are mainly graphical, thus non-portable.). Quote: If that's the case, I'll take down my page and let you guys handle things. I was never really interested in being in the BoE business anyway, I just got the character editor up and running because there had been so much whining about it. Celtic Minstrel is the one maintaining/upgrading the Mac version of BoE, so he may have already merged your code... Oh, and you may safely go back to the BoA 3D Editor (or AScript project, or whatever you're working on), we will try to handle the (potential) whining Chokboyz Quote Link to comment Share on other sites More sharing options...
Understated Ur-Drakon Celtic Minstrel Posted April 18, 2009 Share Posted April 18, 2009 About the BoE code, I completely ignored the version of it on the darcs repository and used Niemand's source as a basis instead. Quote Link to comment Share on other sites More sharing options...
Well-Actually War Trall Niemand Posted April 18, 2009 Share Posted April 18, 2009 So it sounds like the answer is yes, you do already have my alterations. So, I shall consider the problem turned over to you. Also: This means you get to deal with Bain's crazy bug. Ha! (That is, of course, if the bug still exists in your version.) If you want, I can send to you the small amount of information I had gathered on it. Quote Link to comment Share on other sites More sharing options...
Understated Ur-Drakon Celtic Minstrel Posted April 19, 2009 Share Posted April 19, 2009 I have no idea if the bug still exists, but there's currently a bug that prevents you from ever opening a file, so I kind of need to fix that first... though I suspect it may be fairly simple. Also, what kind of thing would cause them to quit immediately when launching from the Finder but not when launching from Xcode? I think all three of them currently do that, which is another thing that needs fixing. Quote Link to comment Share on other sites More sharing options...
Well-Actually War Trall Niemand Posted April 19, 2009 Share Posted April 19, 2009 I don't really know how either thing could happen, maybe tomorrow I can check out another copy of your code and have a look. Quote Link to comment Share on other sites More sharing options...
Understated Ur-Drakon Celtic Minstrel Posted April 19, 2009 Share Posted April 19, 2009 Sure, if you like. All the changes are now in the repository. When you select "Open" from the File menu, the PC editor displays an error message about the save file not being valid – without even prompting you for a file first. EDIT: I think I've solved the "can't open any file" problem – for some reason I think sys_7_avail was false, so it was skipping the chunk of code that displayed the nav file dialog. EDIT2: At least it lets you pick a file now; however, it still fails to load. Quote Link to comment Share on other sites More sharing options...
Well-Actually War Trall Ishad Nha Posted April 20, 2009 Author Share Posted April 20, 2009 This link seems not to be working: http://openexile.googlecode.com/svn/trunk/openexile-read-only Is there any way to download the entire source code all at once rather than just one file at a time? Quote Link to comment Share on other sites More sharing options...
Well-Actually War Trall Niemand Posted April 20, 2009 Share Posted April 20, 2009 The URL is http://openexile.googlecode.com/svn/trunk/ . The last bit is separated by a space; it's a directory name that Google Code thinks you should check the source out to. Ignore it, and use whatever directory you like. Quote Link to comment Share on other sites More sharing options...
Well-Actually War Trall Ishad Nha Posted April 20, 2009 Author Share Posted April 20, 2009 Right, downloaded the code and compiled it, all seems to be looking good. Quote Link to comment Share on other sites More sharing options...
Understated Ur-Drakon Celtic Minstrel Posted April 20, 2009 Share Posted April 20, 2009 Would you like commit access, Ishad, so you can upload your own fixes? If so, email me. Quote Link to comment Share on other sites More sharing options...
Well-Actually War Trall Ishad Nha Posted April 21, 2009 Author Share Posted April 21, 2009 Probably not, I will be concentrating more on other programs. Then I have my life outside this forum. My fixes would need to be checked by someone who can actually program, who really knows what they are doing. Quote Link to comment Share on other sites More sharing options...
Understated Ur-Drakon Celtic Minstrel Posted April 21, 2009 Share Posted April 21, 2009 Then send the code to Chokboyz so he can commit it? Quote Link to comment Share on other sites More sharing options...
Well-Actually War Trall Ishad Nha Posted April 21, 2009 Author Share Posted April 21, 2009 No need, it is his code that I am using anyway. Quote Link to comment Share on other sites More sharing options...
Rotghroth Rhapsody Chokboyz Posted April 24, 2009 Share Posted April 24, 2009 New version of the char editor code is uploaded. I found several bugs that needed to be fixed and made some additions. Changelog : - Corrected the edit day option so that it sets the day to the one specified and not to the day after. Not a crucial one, but fixed anyway (original bug). - Fixed the saving function : now changes can be saved outdoors (that was crashing at save stored_items making give_map non functional). That also fixes the stored items arrays being filled with items from current town. Major bug that was present in the original (Ormus) code. The current_town_item_list was used to fill the stored_item array, resulting in : The stored array being filled by the items in current town if in town. When loading a new scenario, the game would propose the player to get these items. The saving function returning before ending with outdoor, not saving the maps. The give map options were then useless. - If in a scenario, the editor nows display the name of the town the party is in or if they are outdoor. (even while in a Mac made scenario) - Giving PC items from a Mac made scenario doesn't crash the game anymore (overall Mac scenario support added) Big/little endian adjustment. If giving items from a scenario made on mac, the game would crash when using them, getting info on them, etc ... - Cleaned the ressource file. The executable is now smaller. But more can be done with the code i'm sure - On give items : the editor now tries to load the bladbase.exs file if the scenario file is not found. If can't locate the bladbase, the items menus are grayed. Thus preventing clicking on unallocated items. The Character Editor should now be fully operational. Chokboyz Quote Link to comment Share on other sites More sharing options...
Understated Ur-Drakon Celtic Minstrel Posted April 24, 2009 Share Posted April 24, 2009 So the character editor doesn't have a hard-coded item list like it used to? Quote Link to comment Share on other sites More sharing options...
Rotghroth Rhapsody Chokboyz Posted April 24, 2009 Share Posted April 24, 2009 Quote: So the character editor doesn't have a hard-coded item list like it used to? Exactly, it now loads the item list (and the town names, ...) right from the scenario file. Chokboyz Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.