Opry99er Posted July 16, 2016 Share Posted July 16, 2016 Hey Rasmus, is there any way to run Magellan from a usb stick? Work computer is pretty tight on installs. Quote Link to comment Share on other sites More sharing options...
LASooner Posted July 17, 2016 Share Posted July 17, 2016 If you have JAVA installed, you can just run the JAR file from the USB stick without having to install it. I think the JAVA install is the part your IT department would have a problem with. Quote Link to comment Share on other sites More sharing options...
Opry99er Posted July 17, 2016 Share Posted July 17, 2016 Thanks! Quote Link to comment Share on other sites More sharing options...
Sinphaltimus Posted October 28, 2016 Share Posted October 28, 2016 (edited) What could cause the Export to XB Program to stop working? I even reinstalled. I select that option and nothing happens anymore. Worked fine yesterday.Could it be some mode I'm in? Can I delete an ini or something?Export Assembly data works but not BASIC or XB.II see others ran in to this. Going to try deleting prefs and looking for the latest version.EDIT: OK Uninstalled, reinstall worked. Edited October 28, 2016 by Sinphaltimus Quote Link to comment Share on other sites More sharing options...
Asmusr Posted October 28, 2016 Share Posted October 28, 2016 I haven't looked at the XB export for ages. Let me know if there are bugs or if you have suggestions for improvement. Quote Link to comment Share on other sites More sharing options...
Sinphaltimus Posted October 28, 2016 Share Posted October 28, 2016 I dunno. It can probably do everything I need it to but I haven't really gotten too deep in to it. It just stopped exporting xb for some reason. Uninstalled and reinstalled fixed that issue. I should probably look for the manual.. Quote Link to comment Share on other sites More sharing options...
Davvel Posted November 27, 2016 Share Posted November 27, 2016 It stopped exporing assembler data for me too. But a quick re-install fixed it. Quote Link to comment Share on other sites More sharing options...
Asmusr Posted November 28, 2016 Share Posted November 28, 2016 This should fix the problem with the export dialog not working. Magellan_windows-x64_3_0_5.zip Magellan_windows_3_0_5.zip Magellan-3.0.5.zip 4 Quote Link to comment Share on other sites More sharing options...
Davvel Posted November 29, 2016 Share Posted November 29, 2016 This should fix the problem with the export dialog not working. Thanks. Quote Link to comment Share on other sites More sharing options...
Davvel Posted November 29, 2016 Share Posted November 29, 2016 This should fix the problem with the export dialog not working. As I have posted in another thread, I have some ideas for improvement , given you have some time to invest in this great tool, I am willing to document and send you what I have in mind. I use Magellan quite often now and feel that it lacks a few key functions that could make our lives easier. I will mention just 1 or 2 here - 1. Right clicking on a character in the map area will open a context sensitive menu which shows several options, for example: * Go to character definition 2. Undo function for the times we mess up the map area by mistake. At least 1 undo step. Thanks. David 1 Quote Link to comment Share on other sites More sharing options...
Sinphaltimus Posted November 30, 2016 Share Posted November 30, 2016 (edited) I'd like to be able to paste at least 64 character code in to the dialog box and it will auto populate the next ascii codes to accommodate (paste 32 at ascii code 33 and ascii codes 33 and 34 get filled in appropriately or 64 and 33-36 get filled in appropriately.). Kind of like the "sprite" functionality but not a sprite. Edited November 30, 2016 by Sinphaltimus Quote Link to comment Share on other sites More sharing options...
Asmusr Posted November 30, 2016 Share Posted November 30, 2016 As I have posted in another thread, I have some ideas for improvement , given you have some time to invest in this great tool, I am willing to document and send you what I have in mind. I use Magellan quite often now and feel that it lacks a few key functions that could make our lives easier. I will mention just 1 or 2 here - 1. Right clicking on a character in the map area will open a context sensitive menu which shows several options, for example: * Go to character definition 2. Undo function for the times we mess up the map area by mistake. At least 1 undo step. Thanks. David 2. Already exists. Buttons in the top left right corner. Quote Link to comment Share on other sites More sharing options...
Asmusr Posted November 30, 2016 Share Posted November 30, 2016 And 1. is the Eye icon. Quote Link to comment Share on other sites More sharing options...
Davvel Posted November 30, 2016 Share Posted November 30, 2016 And 1. is the Eye icon. Rasmus, Thanks for both 1 and 2, I will not try to justify why I never found those, probably because I did not read the manual or looked hard enough, but having the "eye" icon grouped with the Map related icons and CTRL Z to undo might have been a little more obvious for me. Having said this once you know where they are, they are good enough as is. I will put down some more ideas, maybe the following are not too hard to obtain and will be useful for your game creations too : 1. When one imports a Map Image, sometimes many unnecessary repeated characters get created, one could refine the import to have a tolerance threshold entered whereby if a character is already being utilised but is just for 1 or 2 pixels different from an already created character, then that character is used instead and a new one is not created. 2. Similar to 1, One can also instruct the import that the destination Map Image is monochrome and all colours in source should be ignored so it will not create extra similar character just to provide a different colour. I go around this by changing the source image to black and white, but it does not always work right. 3. One can create a bulk move characters as follows (Enhancing the Replace function that we have today) - Probably this applies only for colour mode 0 - User inputs a number representing the source row by specifying the first character in that row (0,8,16....) drop down list User inputs the number of rows to move (1,2,3) drop down list User inputs the destination row (32,40,48 etc...) drop down list User selects if colour table should be swapped as well. check box <User presses OK> The characters and colour table will then be swapped or moved. This is needed to reorganise characters stacking them neatly usually after a map import. 4. Points 1 and 2 will also be available post import. Let's say you have created a map which contains waste in characters, you can have a button to analyse such waste and offer you to auto fix that waste by replacing similar characters, especially if the output image is monochrome. One can also limit the function to a range of characters it should analyse and fix, not to disturb other characters outside that range. Thanks David Quote Link to comment Share on other sites More sharing options...
Asmusr Posted November 30, 2016 Share Posted November 30, 2016 ..., but having the "eye" icon grouped with the Map related icons ... might have been a little more obvious for me. It would indeed, but this was there before my time. Re 1: The map import code is quite complex as it is, but I guess that should be possible. Re 2: Well, the workaround is quite easy, so I don't think it's something I would do. Note that you can provide a hint to the import routine about what the background color should be by choosing this as the screen color first. Re 3: Yes the bulk move could be improved a lot. Something I use a lot is to click on a character, the press shift and click on another character to swap them. It's quite fast to reorganize your character set this way. 2 Quote Link to comment Share on other sites More sharing options...
Davvel Posted November 30, 2016 Share Posted November 30, 2016 Re 1: The map import code is quite complex as it is, but I guess that should be possible. Today I took the plunge, downloaded IntelliJ 2016.3 for the first time of my life and fired up the Magellan source code. (I was a C# guy back in 2002-2006 and never used Java - I skimmed OOP as in my programming years I always developed with non OOP languages). I dug deep in the functions that analyse the RGB and check if a character is new or same. It was tough... I managed to change behaviour and reduce some over usage but I am not happy. I am attacking primarily public static boolean gridEquals(int[][] grid1, int[][] grid2). I tried finding ways of analysing change and detecting if change is minimal, but it is much harder than I thought it would be. I even tried converting RGB value to Mono, ignoring the colour component, but results were not what I expected. I am sure that the solution will be a few lines of code, but like when preparing food, the ingredients are simple but their combination is complex Just out of curiosity can you please indicate if I am decomposing the RGB integers properly ? gr1=grid1[y][x]; r1 = (gr1 >> 16) & 0xFF; // red g1 = (gr1 >> 8) & 0xFF;// green b1 = gr1 & 0xFF;//blue David Quote Link to comment Share on other sites More sharing options...
Asmusr Posted November 30, 2016 Share Posted November 30, 2016 Just out of curiosity can you please indicate if I am decomposing the RGB integers properly ? gr1=grid1[y][x]; r1 = (gr1 >> 16) & 0xFF; // red g1 = (gr1 >> 8) & 0xFF;// green b1 = gr1 & 0xFF;//blue David Yes that looks right, but I think perhaps the gridColorDistance method is what you need. Quote Link to comment Share on other sites More sharing options...
Davvel Posted November 30, 2016 Share Posted November 30, 2016 Yes that looks right, but I think perhaps the gridColorDistance method is what you need. Thanks for your prompt reply. You are right, I shall dig into that method as it looks promising. Quote Link to comment Share on other sites More sharing options...
Davvel Posted November 30, 2016 Share Posted November 30, 2016 Rasmus, Thanks for your guidance, I have added this function which needs to be called only from one place as when I replaced both places it is called from it will produce unwanted results. The 200 seen below, needs to be a variable fed by the user. I got good results with some images if I make it 1000, but for other hand drawn images it needs to be low <200. Compression so far is good. For hand drawn simple image I recorded the following results: 100 = approx. 90% of original with no loss, 200=approx. 50% with almost no difference, 300= approx. 40% of original with some loss For complex images with a lot of detail I got amazing cleaning of unwanted colours when using a value of 6600. I am attaching the images for you to experiment with tree2.png requires 6600 to clean up tree4.png and tree5.png needs a value of 200-300 or else will disappear. New Method in Global class: public static boolean gridEquals2(int[][] grid1, int[][] grid2) {long distance = 0;for (int y = 0; y < grid1.length; y++) {for (int x = 0; x < grid1[0].length; x++) {distance += colorDistance(grid2[y][x], grid1[y][x]);}}if ( distance>200 ) {return false;}return true;} Called from only this method: // Check if pattern already existsint ch = -1;for (int i = 0; i < patterns.size() && ch == -1; i++) {if (Globals.gridEquals2(rgbGrid, patterns.get(i).getFirst())) {ch = i;}} Quote Link to comment Share on other sites More sharing options...
Davvel Posted November 30, 2016 Share Posted November 30, 2016 What I am noticing, is that since I did this colour distance function many images that used to give me "ERROR" when loading, such as images larger than 240 by 160 pixels now load perfectly but create a very large map. Quote Link to comment Share on other sites More sharing options...
Davvel Posted November 30, 2016 Share Posted November 30, 2016 The attached image is a good example of importing a large image made possible with some tollerance. A value of 3600 removed the error from appearing. Quote Link to comment Share on other sites More sharing options...
Asmusr Posted November 30, 2016 Share Posted November 30, 2016 The attached image is a good example of importing a large image made possible with some tollerance. A value of 3600 removed the error from appearing. snowtree.png Thanks, I'm looking into fixing that error. Just need to remember how the import works. Quote Link to comment Share on other sites More sharing options...
Sinphaltimus Posted November 30, 2016 Share Posted November 30, 2016 Re 3: Yes the bulk move could be improved a lot. Something I use a lot is to click on a character, the press shift and click on another character to swap them. It's quite fast to reorganize your character set this way. I could have use THAT info last week! LOL. Holymollies.. 1 Quote Link to comment Share on other sites More sharing options...
Davvel Posted November 30, 2016 Share Posted November 30, 2016 (edited) AsmusR et all Success at last... my first Java end to end modification I am so pleased I can send you the modified code if you want to include in GitHub. I do not feel I can be presumptuous and add any code to this work without a peer review. Regards David Edited November 30, 2016 by Davvel Quote Link to comment Share on other sites More sharing options...
Asmusr Posted November 30, 2016 Share Posted November 30, 2016 Great, I have also made more or less the same changes, in addition to fixing the import bug. I used a logarithmic slider for the tolerance because I figured the numbers don't mean anything. We better get this into GitHub if you or others want to continue working on it, but I'm a bit reluctant to do this without the consent of The Codex. Magellan_windows-x64_3_1.zip Magellan_windows_3_1.zip Magellan_3_1.zip 3 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.
Note: Your post will require moderator approval before it will be visible.