broncepulido Posted December 9, 2021 Report Share Posted December 9, 2021 Great! Thanks! Quote Link to comment Share on other sites More sharing options...
donaldseadog Posted December 9, 2021 Author Report Share Posted December 9, 2021 6 hours ago, TonyE said: The code checks both minimum and total victory conditions and records the time each level is met for each side. Those 3 changes sound good to me. Regards the recording can I access that via exportDLL? Or can I catch it as it tests positive, is it an 'event'? I've been meaning to chase that up for my AAR-Report.dll. Don (ed) Quote Link to comment Share on other sites More sharing options...
TonyE Posted December 10, 2021 Report Share Posted December 10, 2021 15 hours ago, donaldseadog said: Those 3 changes sound good to me. Regards the recording can I access that via exportDLL? Or can I catch it as it tests positive, is it an 'event'? I've been meaning to chase that up for my AAR-Report.dll. Don (ed) Update: My tests are working as expected though they are nowhere near comprehensive. Next: Refactoring the data structures used to track the VC completion. Right now it is a combination of a three dimensional array (time each victory level was reached for each side against each other side), one dimensional array (sides that only have total victory conditions), and a couple of individual variables (first side to hit min_vic, time of first min_vic and first side to hit tot_vic and time of the first tot_vic). Modifying the saved game structure to store what needs to persist across sessions. This will also include a converter for existing saves. The new logic cannot be properly seeded from an existing saved game so the best approach will be to abandon existing saved games but we'll load them and populate what we can on victory achievement. Possibly modifying the scenario file structure as a result of changing the VictoryConditions structure. The VictoryConditions structure change would likely be adding a GameTime field that is populated when that particular VC is met and a target side that indicates the 'enemy' side for the VC. Currently VCs are strictly Red v Blue and Blue v Red so when I'm mucking in structures I like to expand that. Exposing the data to ExportDLLs which at a minimum means updating the interface version. The current victory status should come through in new globals and if the VictoryConditions structure changes, updates to match them. I just checked and the globals are not exposed to the ExportDLL interface yet so that may be a piece of this too. Quote Link to comment Share on other sites More sharing options...
donaldseadog Posted December 11, 2021 Author Report Share Posted December 11, 2021 And it sounded so simple Quote Link to comment Share on other sites More sharing options...
TonyE Posted December 13, 2021 Report Share Posted December 13, 2021 Progress. Added tracking of individual Victory Condition time achieved and exposed to ExportDLL as part of the Globals structure in ScenLoad. Most of the Globals structure is still opaque to the ExportDLLs, will build out the THCGlobals typedef over time. Quote Link to comment Share on other sites More sharing options...
TonyE Posted December 13, 2021 Report Share Posted December 13, 2021 Okay, done and uploaded as 2021.009 and an updated lazGUI ExportDLL for the ExportDLL pieces. You will see some victory messages in the MessageLog window and different ones in the ge.log file. 1 Quote Link to comment Share on other sites More sharing options...
TonyE Posted December 14, 2021 Report Share Posted December 14, 2021 I ran a couple of statistics for the Harpoon code changes, the lazGUI and shared ExportDLL code changes aren't included in the counts. The victory condition work added 810 lines of code and removed 367 lines of code. Those changes affected 32 source code files. Quote Link to comment Share on other sites More sharing options...
donaldseadog Posted December 15, 2021 Author Report Share Posted December 15, 2021 I better get lazarus loaded on the new computer and have a looky. Prob in a few days as we're away doing pseudo xmas family stuff. 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.