planet_generator 0.0.7-pre-alpha

[WIP] Generates data for galaxies, sectors, solar systems, planets and their inhabitants (Check README for features list).
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
use crate::internal::*;
use crate::prelude::*;
pub mod elements;
pub mod generator;
pub mod types;
pub mod utils;
pub mod zones;

/// Returns the next unused identifier that can be assigned to an [OrbitalPoint].
fn get_next_id(existing_objects: &Vec<OrbitalPoint>) -> u32 {
    existing_objects.iter().map(|o| o.id).max().unwrap_or(0) + 1
}