Since implementing the farming feature, we've realized that the Wheat assets were too detailed and difficult to interpret. Here's an improved version that's less noisy, uses a better color coding, and introduces two new growth stages: Dry and Dead. Remember to keep your crops watered!

ReactReply

Using Bevy's AsyncComputeTaskPool to find the shortest path to any destination among a set of potential destinations without blocking the main thread. Rust is neat!

// Find the shortest path to any tile in a set of tiles.
fn calculate_shortest_path(
    start: TilePos,
    destinations: HashSet,
    tilemap_id: TilemapId,
) -> Result>, HommletError> {
    // Resolve the operation asynchronously.
    let async_task = AsyncComputeTaskPool::get().spawn(async move {
        // For each destination tile, calculate a path.
        // Then, find the shortest path.
        AsyncComputeTaskPool::get()
            .scope(|s| {
                destinations.iter().for_each(|&destination| {
                    s.spawn(async move { path_to_tile(tilemap_id, start, destination) })
                });
            })
            .into_iter()
            .flatten()
            .min_by_key(|path| path.nodes.len())
            .ok_or(HommletError::FailedToFindPathInSet)
    });

    Ok(async_task)
}
🤙1ReactReply

Spent a couple days this week working on basic farming. We don't expect the cult will farm wheat for long, but it makes for a good start.

ReactReply

We're experimenting with a new character style!

🤩3ReactReply