Skip to content

Commit cb9eecb

Browse files
authored
Fix variable reference
The example refers to an undefined variable `transform`
1 parent f6dcec4 commit cb9eecb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

bevy-cookbook.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ fn my_cursor_system(
126126
let p = ev.position - size / 2.0;
127127

128128
// apply the camera transform
129-
let pos_wld = transform.value * p.extend(0.0).extend(1.0);
129+
let pos_wld = camera_transform.value * p.extend(0.0).extend(1.0);
130130
eprintln!("World coords: {}/{}", pos_wld.x(), pos_wld.y());
131131
}
132132
}

0 commit comments

Comments
 (0)