pite_core/nodes/
camera2d.rs1use crate::schema::{DefaultPropVal, NodeTypeSchema, PropHint, PropSchema};
5
6pub static SCHEMA: NodeTypeSchema = NodeTypeSchema {
7 type_name: "Camera2D",
8 description: "Frames the view: the screen centers on this node's global position.",
9 inherits: Some("Node2D"),
10 abstract_class: false,
11 props: PROPS,
12};
13
14pub static PROPS: &[PropSchema] = &[PropSchema {
15 key: "zoom",
16 label: "Zoom",
17 doc: "View scale; larger values show less of the world. Multiplied by the window fit scale.",
18 default_value: DefaultPropVal::Num(1.0),
19 hint: PropHint::Num {
20 speed: 0.05,
21 min: 0.01,
22 max: 100.0,
23 },
24 read_only: false,
25}];