POC: Inital commit (transcode json, ron, yaml)
This commit is contained in:
26
examples/gameConfig.ron
Normal file
26
examples/gameConfig.ron
Normal file
@ -0,0 +1,26 @@
|
||||
GameConfig( // optional struct name
|
||||
window_size: (800, 600),
|
||||
window_title: "PAC-MAN",
|
||||
fullscreen: false,
|
||||
|
||||
mouse_sensitivity: 1.4,
|
||||
key_bindings: {
|
||||
"up": Up,
|
||||
"down": Down,
|
||||
"left": Left,
|
||||
"right": Right,
|
||||
|
||||
// Uncomment to enable WASD controls
|
||||
/*
|
||||
"W": Up,
|
||||
"A": Down,
|
||||
"S": Left,
|
||||
"D": Right,
|
||||
*/
|
||||
},
|
||||
|
||||
difficulty_options: (
|
||||
start_difficulty: Easy,
|
||||
adaptive: false,
|
||||
),
|
||||
)
|
4
examples/simple.json
Normal file
4
examples/simple.json
Normal file
@ -0,0 +1,4 @@
|
||||
{
|
||||
"a boolean": true,
|
||||
"an array": [3, 2, 1]
|
||||
}
|
20
examples/standard.ron
Normal file
20
examples/standard.ron
Normal file
@ -0,0 +1,20 @@
|
||||
Scene( // class name is optional
|
||||
materials: { // this is a map
|
||||
"metal": (
|
||||
reflectivity: 1.0,
|
||||
),
|
||||
"plastic": (
|
||||
reflectivity: 0.5,
|
||||
),
|
||||
},
|
||||
entities: [ // this is an array
|
||||
(
|
||||
name: "hero",
|
||||
material: "metal",
|
||||
),
|
||||
(
|
||||
name: "monster",
|
||||
material: "plastic",
|
||||
),
|
||||
],
|
||||
)
|
Reference in New Issue
Block a user