remove avatar (treat it as sprite)

This commit is contained in:
2020-06-18 17:46:30 +01:00
parent 4430ee74aa
commit bf5b3a8d20
2 changed files with 35 additions and 41 deletions

View File

@@ -767,38 +767,40 @@ pub fn game_default() -> Game {
walls: vec![],
}],
tiles: vec![self::tile_default()],
avatar: Sprite {
id: "A".to_string(),
animation_frames: vec![Image {
pixels: vec![
0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0,
1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 1, 0, 1, 1, 1, 1, 0, 1, 0, 0, 1, 0,
0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0,
],
}],
name: None,
room_id: Some("0".to_string()),
position: Option::from(Position { x: 4, y: 4 }),
colour_id: None,
dialogue_id: None,
items: vec![]
},
sprites: vec![Sprite {
id: "a".to_string(),
name: None,
animation_frames: vec![Image {
pixels: vec![
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1,
1, 1, 0, 0, 0, 1, 0, 1, 1, 1, 0, 0, 1, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1,
1, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0,
],
}],
dialogue_id: Some("SPR_0".to_string()),
room_id: Some("0".to_string()),
position: Some(Position { x: 8, y: 12 }),
colour_id: None,
items: vec![]
}],
sprites: vec![
Sprite {
id: "A".to_string(),
animation_frames: vec![Image {
pixels: vec![
0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0,
1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 1, 0, 1, 1, 1, 1, 0, 1, 0, 0, 1, 0,
0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0,
],
}],
name: None,
room_id: Some("0".to_string()),
position: Option::from(Position { x: 4, y: 4 }),
colour_id: None,
dialogue_id: None,
items: vec![]
},
Sprite {
id: "a".to_string(),
name: None,
animation_frames: vec![Image {
pixels: vec![
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1,
1, 1, 0, 0, 0, 1, 0, 1, 1, 1, 0, 0, 1, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1,
1, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0,
],
}],
dialogue_id: Some("SPR_0".to_string()),
room_id: Some("0".to_string()),
position: Some(Position { x: 8, y: 12 }),
colour_id: None,
items: vec![]
},
],
items: vec![Item {
id: "0".to_string(),
animation_frames: vec![Image {