MAP FORMAT
circuitbone opened this issue · comments
The structure of all maps and the inherited data with each map.
Template Starter Map
Minimum Map Requirements
- Smøl closed 3d map course shape
- External background 3d around course
- Course Sign in background tiles
- Start Player Location
- End goal Location
Standard Assets with every course
- Blocks - Building Blocks
- 3D Flag
- Visual 3d Indicators
- Visual 3d Player
Theme
- Classic Assets Theme
- Theme is network based so everyone has the same assets.
- Assets are pulled from a central server location so all clients share the same objects
File Folder Structure
- Project structure
- Basic Folder Structure
- Project File Name / Extension
- Basic Blocks
- Basic Course Obstacles
Map Structure (JSON) - Current
{
"id": "",
"title": "Untitled Map",
"spawn": "0 0 0",
"size": 100,
"world": {
"sky": {
"color": "#FFFFFF",
"scatter": "#FFFFFF",
"sun": "#FFFFFF"
},
"lights": {
"ambient": {
"color": "#FFFFFF",
"intensity": 1.0
},
"directional": {
"color": "#FFFFFF",
"intensity": 1.0
}
},
"physics": {
"gravity": -0.9
}
},
"objects": [{
"id": "",
"label": "cube",
"active": false,
"category": "block",
"type": "cube",
"position": "1 1 1",
"rotation": "0 0 0",
"color": "#EEEEEE",
"texture": "",
"physics": {}
},{
"id": "",
"label": "point",
"active": false,
"category": "entity",
"type": "point",
"position": "1 1 1",
"rotation": "0 0 0"
},{
"id": "",
"label": "modelName",
"active": false,
"category": "model",
"type": "modelName",
"position": "1 1 1",
"rotation": "0 0 0",
"material": "materialName"
}]
}
@circuitbone I have the ability to enable automatic updates when the application starts. We can supply models from the server so the players have them locally. For playing maps made by other players, we will need to figure out how much customization they are allowed including adding custom models etc. In any case, the models are loaded via datauri and sent as json to the editor / game state...so it’s probably good that most of these models are small in filesize anyway.
Think of customer contribution assets down the track, moderation problem and validation is labour intensive for now.
- automatic startup app network asset update sounds good mate.
- save maps to server from any client and show this list to all clients for now until we need to restrict it
- load maps from server from any client and show this list to all clients for now until we need to restrict it
My goto JSON editor
Map parameter ideas
-
course_name
-
hole_number
-
sign_string
-
Physics Global Friction Rubber
-
Physics Global Friction Ice
-
Physics Global Friction AntiRubber
-
Weather_event_Clouds
-
Weather_event_Rain
-
Weather_event_WindLeaf_Particles
Suggestion for map format: Use TMX format, to make it interchangable with other engines and frameworks. As well at mini-golf itself, ofcourse ;)