pioneer/scripts
Gliese852 af5d52cfd9 Move the System Map to PiGUI
The main idea of the interaction of lua side and C++ side is the same as
in the worldview - the C++ View Class builds three-dimensional objects,
some projected points are passed to the lua script, the lua script only
works with screen coordinates.

The difference between the system view and the world view is that not
all objects can have a physical body. If we examine a non-current star
system, we see only system bodies that do not have physical bodies.
Therefore, if for a world view you can simply create an array of
physical bodies, this will not work in a system view.

To solve this problem, struct "Projectable" was created, into which you
can write any point object, system body, ship, Lagrange point,
apocenter, pericenter, etc. Now all these objects can be processed in a
single array.

The names of the types of these objects are recorded in an enum, which
is exported to a enum_table.cpp and read by the script as integers at
the start. I thought it was better to avoid passing strings in such a
hot place in the code. (runs for every object in every frame) Therefore,
type names are written and transmitted as integers.

All colors are now imported from lua: color index names are listed in
the enum, which is exported to the enum_table.cpp. At event
"onGameStart" the lua script reads these names and sends color values to
the class. Now you can change colors at runtime.

* Improvements/fixes: *

- Fix zooming speeds.
- Fix ship's orbits in nonroot frame.
- Remove unused old gui objects.
- Landed ship are now spinning with the planet when rewinding time in a
    planner.
- Now you can center the view on any object, including the player’s ship.
- Add right-click context menu to center or set object as target.
    Therefore, to rotate the view, set the middle button.
- Add indicators for navigation target and combat target.

* Changes in the files explained *

    SystemView.cpp, SystemView.h, system-view-ui.lua, lang/core/en.json

The whole thing, lots of changes. Now the system view draws only the
orbits and the grid. In those places where the icons were drawn, instead
of drawing, they are stored in an array, which is then requested from
the lua.

    LuaEngine.cpp

Add a general function that returns the value of an any enum by name
from an enum_table.cpp (for calling from a lua)

    Space.cpp

Added a notification for the systemview when the ship is removed from
space, because it can be centered at this time, and an segmentation
fault will occur.

    LuaSystemBody.cpp

Added attributes to determine the shape of the icon and set the
navigation target.

    enum_table.cpp, enum_table.h

Rescanned enums to pass color settings and object types between Lua and
C++.

    LuaGame.cpp

The float does not have enough accuracy to display time up to seconds,
change to double.

    icons.svg, themes/default.lua

Add rotate view icon
2020-04-04 11:56:10 +03:00
..
Pioneer.cppcheck Default configuration for CppCheck, useful for static analysis of codebase. 2014-11-29 13:18:29 +00:00
ShipPlanner015.py Fixing a typo on retro thrust writing an extra "2" on the end of the number, making it ten times more pwerful than it should be. 2016-03-06 12:49:13 +01:00
build-osx.sh Tidy up the script and remove the duplicate library. Closes #4181 2017-10-14 22:34:15 +10:00
build-travis.sh Update scripts 2020-03-13 14:06:52 -04:00
canonicalise_translations.py replace shell+perl canonicalise-translations.sh with a Python script 2015-12-25 20:39:25 +00:00
clang-format.sh Remove GITHUB_WORKSPACE in clang-format.sh 2020-03-24 13:13:30 -04:00
clean_lang_data.py add a python script to clean up language data files 2013-10-14 01:51:35 +01:00
galgen_verify.sh Add galaxy verification script. 2014-09-06 22:43:23 +02:00
move_translation.py add utility script scripts/move_translation.py 2015-12-25 21:31:38 +00:00
nightly-build.pl Include README.md in official build 2016-08-15 13:51:03 +02:00
parse_gliese3.py lots of custom systems imported from star catalogue 2008-12-30 19:58:32 +00:00
parse_hygxyz.py parse_hygxyz script to import starmap 2011-08-01 14:39:45 +01:00
prep-changelog.pl rework changelog prep script to cope with month "version" 2013-05-13 21:53:53 +10:00
scan_enums.py Move the System Map to PiGUI 2020-04-04 11:56:10 +03:00
sketchfab.json Add new ship Lodos to sketchfab wiki json file 2018-08-03 08:53:38 +02:00
update-translations.sh buildbot translation update script 2014-04-05 21:10:23 +11:00
wiki_ship_stat_parser.py Fix script for wiki syntax for generating ships table. 2018-08-01 21:22:49 +02:00