MCPcopy Create free account
hub / github.com/CleanCut/invaders / draw

Method draw

src/menu.rs:33–40  ·  view source on GitHub ↗
(&self, frame: &mut Frame)

Source from the content-addressed store, hash-verified

31// Reuse Frame grid to print the menu options
32impl Drawable for Menu {
33 fn draw(&self, frame: &mut Frame) {
34 frame[0][self.selection] = '>';
35 for (index, option) in self.options.iter().enumerate() {
36 for i in 0..option.len() {
37 frame[i + 1][index] = self.options[index].chars().nth(i).unwrap();
38 }
39 }
40 }
41}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected