TABLE OF CONTENTS
- 1. Maps/Maps
- 1.1. Maps/MUI
- 1.1.1. MUI/MUI.Default_Fonts_Sizes
- 1.1.2. MUI/MUI.MapView
- 1.1.3. MUI/MUI.Create_Game_Ui
- 1.1.4. MUI/MUI.Get_Map_View
- 1.1.5. MUI/MUI.Set_Keys
- 1.1.6. MUI/MUI.Show_Sky_Map
- 1.1.7. MUI/MUI.Update_Header
- 1.2. Maps/Maps.Sky_Cell
- 1.3. Maps/Maps.Empty_Cell
- 1.4. Maps/Maps.Sky_Map
- 1.5. Maps/Maps.Count_Distance
Maps/Maps [ Packages ]
FUNCTION
Provide code for manipulate the game map
SOURCE
package Maps is
Maps/Maps.Sky_Cell [ Records ]
FUNCTION
Data structure for cells in game map
SOURCE
type Sky_Cell is record Base_Index: Extended_Base_Range := 0; Visited: Boolean; Event_Index: Natural := 0; Mission_Index: Mission_Container.Extended_Index := 0; end record;
PARAMETERS
Base_Index - If sky base is in cell > 0 Visited - True if player was in this cell Event_Index - If event is in cell > 0 Mission_Index - If accepted mission is in cell > 0
Maps/Maps.Empty_Cell [ Constants ]
[ Top ] [ Maps ] [ Constants ]
FUNCTION
Default, empty map cell data
SOURCE
Empty_Cell: constant Sky_Cell := (others => <>);
Maps/Maps.Sky_Map [ Variables ]
[ Top ] [ Maps ] [ Variables ]
FUNCTION
Game map
SOURCE
Sky_Map: array(Map_X_Range, Map_Y_Range) of Sky_Cell;
Maps/Maps.Count_Distance [ Subprograms ]
[ Top ] [ Maps ] [ Subprograms ]
FUNCTION
Count distance (in map fields) between player ship and the destination point
SOURCE
function Count_Distance (Destination_X: Map_X_Range; Destination_Y: Map_Y_Range) return Natural with Import => True, Convention => C, External_Name => "countAdaDistance";
PARAMETERS
Destination_X - X coordinate of the destination point Destination_Y - Y coordinate of the destination point
RESULT
Distance between player ship and destination point