scoob
Junior Member

Posts: 57
|
Post by scoob on Oct 24, 2013 17:13:20 GMT -5
Max's eighth or so release. Cool, I'll take some time to try to duplicate Jimmy's fixes first - i.e. the show-stopping targetting bug and the like. Once that's stable I can PLAY! I'm impressed how, yet again, you've found stuff I could not. Cheers, Scoob.
|
|
|
Post by Pilot on Oct 24, 2013 17:27:18 GMT -5
I have a HUGE archive and I'm uploading what I think could be useful or should be around as an additional backup to that link. And seeing as all of that was created by the community I think it should be safe on skydrive unless microsoft (holds breath) goes broke.
|
|
|
Post by rustiswordz on Oct 24, 2013 18:27:24 GMT -5
Be warned Windows LIVe is shut down in June '14 so if skydrive is connected to that...
|
|
|
Post by Pilot on Oct 24, 2013 18:55:40 GMT -5
I think skydrive is under their new ventures. However I'll keep that in mind and create another auxiliary storage.
Edit: I pretty sure it is it uses elements of Windows 8 and Office 365's designs and pushes W8.1 and their mobile app.
|
|
scoob
Junior Member

Posts: 57
|
Post by scoob on Oct 25, 2013 14:13:40 GMT -5
Hey all,
Had some time this evening to start looking through the Enhanced source code that Pilot was so kind to post. All I can say is that I have a new respect for "I'm not a programmer" Jimmy, as looking at Assembly code is giving me a headache! lol. I'm stunned how readable and clear C++ code seems by comparision.
As I've not done assembly before (but I have been a programmer) I'm having to look up EVERYTHING to get an idea what's going on. You can't really even begin to guess like you can with the higher-level "nearly English" languages.
That said, I think I've already identified the Drone upgrade bug, and can correct the code for it. I'm now looking into the Targeting bug, when the game crashes if the targetted pilot has wares on board. It IS pretty tricky going through this stuff though, I'm just taking one .inc at a time!
I've yet to gain any understanding of exactly how the code flows and exactly how HardwarW.exe uses the Enhanced and Enhanced2 mods - I assume it's in effect an override of sorts.
Regardless, I have something to keep my busy over the WE (yes, I have no life) so we'll see how I get on.
Cheers,
Scoob.
|
|
|
Post by Pilot on Oct 25, 2013 14:31:04 GMT -5
That was the reason C++ was created, so it would be easier for humans to read, the good news would be that assembly was an earlier replacement of binary... 101010101101111010110111 read that! Just kidding, but if we could it would be the same as reading HW's source, I assume.
Good Luck, it is to bad I don't think I have a copy of Jimmy's source.
|
|
scoob
Junior Member

Posts: 57
|
Post by scoob on Oct 25, 2013 15:28:48 GMT -5
That was the reason C++ was created, so it would be easier for humans to read, the good news would be that assembly was an earlier replacement of binary... 101010101101111010110111 read that! Just kidding, but if we could it would be the same as reading HW's source, I assume. Good Luck, it is to bad I don't think I have a copy of Jimmy's source. Yep, and Basic was created for those who found that difficult to follow. Actually, my first exposure programming - like many I imagine - was BASIC, so C and C++ did feel quite alien. Assembly though...it really is horrible. Also of course, I'm following other people's code & it's largely undocumented. However, some things are starting to make sense. I've gotten my head around the bits for checking a moths equipment level etc. as part of my upgrade and cargo bug investigations. Well, I can recognise what it's doing, not sure I could make any intelligent changes just yet mind. Still not identified exactly what causes the cargo bug mind. Not to worry about Jimmy's code. I'd love to see it of course, but if you haven't got it you haven't got it, you've already helped me a lot! Cheers, Scoob.
|
|
|
Post by duncan on Oct 26, 2013 2:45:54 GMT -5
As I've not done assembly before (but I have been a programmer) I'm having to look up EVERYTHING to get an idea what's going on. You can't really even begin to guess like you can with the higher-level "nearly English" languages. Scoob, you may want to use a debugger if you are not doing so already. Smurph and/or max were using ollydbg. You can attach it to the harwar process and trace back the origin of crashes, or so I believe. My experience with ollydbg is limited.
|
|
scoob
Junior Member

Posts: 57
|
Post by scoob on Oct 26, 2013 6:02:53 GMT -5
As I've not done assembly before (but I have been a programmer) I'm having to look up EVERYTHING to get an idea what's going on. You can't really even begin to guess like you can with the higher-level "nearly English" languages. Scoob, you may want to use a debugger if you are not doing so already. Smurph and/or max were using ollydbg. You can attach it to the harwar process and trace back the origin of crashes, or so I believe. My experience with ollydbg is limited. Hi Duncan, Yes, I grabbed OllyDbg. Need to practise with it as the very first time I used it - attaching it to HardwarW.exe - it first crashed my PC to desktop. Then enabled by 2nd monitor and moved all my desktop icons to it. Weird! I've really just been scanning the code thus far, seeing if I can make sense of it. I will do as you suggest and start properly debugging soon. Last night, I just wanted to play the game for a bit. I'm actually tempted - assuming I can re-create Jimmy's fixes - to try to tweak the Eco settings directly in Enhanced. The external .dll EconMod was evidently never quite finished as the results are so unreliable. Cheers, Scoob.
|
|
|
Post by Pilot on Oct 26, 2013 22:01:43 GMT -5
A few of the things that I saw seemed to indicate that the Ecomod.dll may of been it's own thing originally that later became more integrated into Enhanced. Also, though no one seems to bring this up, Enhanced was originally built and designed for the U3.x (1-5) patches, U3.5 is my favorite even though it is unstable, in fact it adds a new moth factory (and I think weapons factory) in it, I wonder why no one has tried to dissect the differences that add those and U06.
|
|
scoob
Junior Member

Posts: 57
|
Post by scoob on Oct 27, 2013 11:02:18 GMT -5
A few of the things that I saw seemed to indicate that the Ecomod.dll may of been it's own thing originally that later became more integrated into Enhanced. Also, though no one seems to bring this up, Enhanced was originally built and designed for the U3.x (1-5) patches, U3.5 is my favorite even though it is unstable, in fact it adds a new moth factory (and I think weapons factory) in it, I wonder why no one has tried to dissect the differences that add those and U06. Yes, that would explain a lot. Econmod was originally part of enhanced, you could switch it off but there was no external .dll. I suspect that certain key elements were simply not offloaded the to .dll during Max's final updates. I will attempt to look into this further. If I can offload more to the dll all the better, cpp is far far easier to work with. My understanding was that Enhanced was re-done to use UIM06 as a base. However, Enhanced is basically a collection of various mods brought together, so possibly some elements were loosly ported to UIM06 but originally created for an earlier version. We know it was very much a WIP for Max when he stopped development and the files were picked up and worked on my Jimmy. I suspect if it was all in cpp then development would have continued / progressed further - assembly is bloody hard though! Scoob.
|
|
scoob
Junior Member

Posts: 57
|
Post by scoob on Oct 28, 2013 11:32:05 GMT -5
Hey all,
Had a little time to play around with Max's Enhanced source again today. I've compiled and tested it directly and the most obvious issues are as follows:
1) There's some sort of queue bug, i.e. I see MANY moths in little clumps, with many such clumps dotted all over the place. Basically, many moths seem to be trying to fly to a given coordinate in space, then this triggers their avoidance routines. Note: they are NOT forming any sort of docking stack. Flippling to Jimmy's Enhanced file, said moths then move to a near-ish hangar, and start forming the expected docking stack - need to find out what the deal is here, but it's obviously linked to route finding / docking somehow. Possibly the new moth avoidance code, though I've not identified that yet.
2) The targetting bug. I thought this bug was a simple case that any moth carrying cargo would trigger the crash if targetted. Fairly simple to track. However, what I'm finding using Max's unchanged Enhanced version is that most moths I target that have cargo work just fine. In my current test save, I've saved just before targeting one moth (out of hundreds tried) that does crash the game. The moth in question is a POLICE moth, so very unlikely to carry any cargo at all. However, this one moth does cause my game to crash.
So, 1) I need to look into further, but regarding 2) does anyone have any more information on what causes this crash? I'm assuming it must be a specific cargo that causes the issue, but unfortunately the log file really isn't any help.
I think I might have to try OllyDbg again, though my first attempt caused problems on my PC.
I'm currently just going through all the separate elements, documenting what I think they do. Should help me build a big picture of what controls what.
Cheers,
Scoob.
|
|
|
Post by duncan on Oct 29, 2013 2:32:14 GMT -5
some ideas
1) maybe the behaviour you observe is tied to the Q-busting routine that max stuck into enhanced. Especially at the start of a new game queue's form at the weapons shops. I believe the Q-busting routine would just teleport moths from the Q to a coordinate in some crater, thus alleviating the Q problem.
2) check if the targeting bug is tied to all moths without cargo or without pod. it could be that enhanced tries to find the cargo in the pod, while none is present. The cargo is stored at another memory address than the moth code - in the moth code there will be a address reference to the cargo - if enhanced takes the value regardless of pod/cargo being present and use it to reference some stuff it could induce a crash perhaps?
|
|
scoob
Junior Member

Posts: 57
|
Post by scoob on Oct 29, 2013 6:44:16 GMT -5
some ideas 1) maybe the behaviour you observe is tied to the Q-busting routine that max stuck into enhanced. Especially at the start of a new game queue's form at the weapons shops. I believe the Q-busting routine would just teleport moths from the Q to a coordinate in some crater, thus alleviating the Q problem. 2) check if the targeting bug is tied to all moths without cargo or without pod. it could be that enhanced tries to find the cargo in the pod, while none is present. The cargo is stored at another memory address than the moth code - in the moth code there will be a address reference to the cargo - if enhanced takes the value regardless of pod/cargo being present and use it to reference some stuff it could induce a crash perhaps? Hi Duncan, Thanks for the input. I think you're right and it's linked to the "improved" queuing in Enhanced. I just need to identify the exact code that controls this and try to disable it for now. It's a shame really as the world feels so alive for those first few minutes as there are hundreds of moths zooming around the moment I exit that first Hangar. Things soon start to go wrong thought lol. I've been reviewing the "Cargo" code, at first glance it looks ok. Basic logic is as follows: - Do I have at least level 1 Target software? No = skip to end. - Do I have at least level 1 Radar software? No = skip to end. - Show Target box (I think) - Get the address of Cargo Slot 1 (used as starting offset) - Loop round all cargo items > Inc loop counter > If loop counter = 6 then exit loop (max 5 cargo bays in pod) > If Item is empty, then go to start of loop > Grab Item Name > Grab Item Quantity > Look up Average Item Value > Multiply Number of Items by avg Value > Loop Logic is a little backwards, at least vs. how I'd have coded it, but it seems ok. Also, I'm assuming that there may be cargo in ANY slot, so all have to be checked. I.e. you buy something, slot one occupied, you buy something else, slot two occupied, you sell what's in slot 1 so only slot 2 occupied. If I can identify the exact cargo scenario that's causing an issue I'll go from there. I may well add an additional check saying "No Pod = no checking". Basically I've been thinking along the same lines as you here, I.e. there's possibly some spurious data in that memory location when no pod is present, and the code needs to trap this BEFORE it starts looking through and assuming it'll be able to find an item / quantity match. Basically I have a plan re: the Cargo bug, but I'm yet to properly identify the code for the Queue / pathing logic & get my head around that. Cheers, Scoob.
|
|
scoob
Junior Member

Posts: 57
|
Post by scoob on Oct 29, 2013 11:48:07 GMT -5
Hmm, found another bug. Or rather, I've confirmed one I suspected. While you can build moths regardless of running the Eco mod or not, you ONLY get the option to Buy the moths you create if the Eco mod is active. Playing Jimmy's version in a current game, build a Swallow (MM Frame needed, not the Swallow Frame) and it doesn't appear to have an ownership limitation. Built some Deaths Heads and Neo Tigers, but can do nothing with them as I have the Eco mod disabled at the moment.
I'll have to see if it's possible to address this as part of my Tweaks. The Eco mod basically breaks the economy, hence why I was running without it *sigh*
Scoob.
|
|