MCPcopy Create free account
hub / github.com/17cupsofcoffee/rl / player

Function player

src/entities.rs:6–12  ·  view source on GitHub ↗
(x: usize, y: usize)

Source from the content-addressed store, hash-verified

4use crate::components::*;
5
6pub fn player(x: usize, y: usize) -> impl Bundle {
7 (
8 Position::new(x, y),
9 Sprite::new('@', Color::WHITE),
10 Movement::new(true, 2, 2),
11 )
12}
13
14pub fn snake(x: usize, y: usize) -> impl Bundle {
15 (

Callers 1

generateMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected