Static World Gen and Display for the Overworld #5

Merged
msrd0 merged 21 commits from overworld-house-gen into main 2024-07-06 20:23:25 +00:00
2 changed files with 7 additions and 4 deletions
Showing only changes of commit ce45bc622d - Show all commits

View file

@ -1,10 +1,10 @@
use comfy::{draw_circle, vec2, EngineContext, GREEN};
use comfy::{draw_circle, draw_sprite, vec2, EngineContext, Vec2, GREEN};
use crate::game::ZLayer;
pub mod worldgen;
pub fn draw(state: &crate::State, _engine: &comfy::EngineContext) {
pub fn draw(state: &crate::State, _engine: &comfy::EngineContext<'_>) {
draw_circle(vec2(0.0, 0.0), 0.5, GREEN, 0);
for (coords, tile) in state.overworld.iter_tiles() {
for (i, texture) in tile.textures.iter().rev().enumerate() {

View file

@ -1,6 +1,6 @@
#[allow(dead_code, unused_variables)]
#![warn(rust_2018_idioms)]
#![forbid(clippy::wildcard_imports, elided_lifetimes_in_paths, unsafe_code)]
#[allow(dead_code, unused_variables)]
mod assets {
include!(env!("ASSETS_RS"));
@ -13,7 +13,10 @@ use self::{
activities::{overworld::worldgen::Overworld, Activity},
assets::Assets
};
use comfy::{GameLoop, EngineState, EngineContext, GameConfig, init_game_config, run_comfy_main_async, pollster};
use comfy::{
init_game_config, pollster, run_comfy_main_async, EngineContext, EngineState,
GameConfig, GameLoop
};
const GAME_NAME: &str = "Powercreep";