-
-
Notifications
You must be signed in to change notification settings - Fork 48
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implement hull, armor and shield components (#1016)
* Remove 8 facet support for armor and shield Remove extra text in ship_view from the C++ end of things (basecomputer) * Implement hull, armor and shield components - Delete Health class. Very similar to Resource. - Move functions to components - e.g. Percent, Get, - Move shield functionality like AdjustPower from DamageableLayer to Shield class - Disable enhance shields from collision. This should probably be handled by a python script. - Delete many functions that are now unused. - Delete x4 sparkling missile - Delete planet.cpp fawg weird hull value - Delete incorrect GetHullPercent by planet. For now it can be damaged and destroyed. - Move some python API from macros to actual code. - Fix issue in energy_container, where Capacitor and FTL Capacitor were not saved. - Add two shield factors in configuration. Currently not read from file. * Fix bug in units.json and ships.json reading. If file doesn't open, game crashes. Polish the code a little. * Tweak the shield modifiers to make the game work better. This stops the shields from eating all the reactor capacity. * Make upgrade view take unit stats into account. Upgrades installed on ship now display damage. Fix bug #1019. Convert Radar_Range to int before saving - prevent exponent format for upgrade view. Fix issue in armor and shield, where Resource was initiated without max value. Use proper string constructor instead. Fix issue in armor, hull and shield, where PercentOperational did not use actual libdamage damage. Fix issue in EnergyContainer applied modifier in the wrong direction. Also, use Serialize to save all three values. Fix issue in Reactor, where Serialize was not used. * Add support for new lib component style upgrade repair Add integral components to ship - hull, afterburner, drive and FTL drive. Fix incorrect reporting of operational as 0-100 and not 0-1. Add missing functions in several components - Damaged, Repair. Fix several bugs in EnergyContainer, including applying fuel_factor to energy and ftl_energy. Correct issue with Reactor incorrectly apply reactor_factor when saving. Fix issue in armor and shield, where the value is read incorrectly. Delete unused code from energetic. * Fix several issues: - Component repairs cost money again - Some sanity checks for eject cargo - Integral components have non-zero volume and mass. Prevent all sorts of nan errors in code. - General repair and refuel no longer repairs integral components. - Shield no longer reports shield strength as percent operational. Damaged/Fixing shields is now also reported correctly. * Fix issue of repairs not costing money. Possible fix for multiple integral components.
- Loading branch information
Showing
57 changed files
with
1,564 additions
and
1,737 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.