Materials¶
Materials are used in the game to set what various surfaces in a stage should look like. In Rolled Out!, materials work by picking a base material (See Base materials), which comes with default values for various properties such as textures, the emissive color, refraction, etc. Stages can then create materials that override those default values, and even animate those properties.
- Base materials
- Description
- rolledout:mat_surface_opaque_lit_generic
- rolledout:mat_surface_masked_lit_generic
- rolledout:mat_surface_translucent_lit_generic
- rolledout:mat_surface_opaque_unlit_generic
- rolledout:mat_surface_masked_unlit_generic
- rolledout:mat_surface_translucent_unlit_generic
- rolledout:mat_surface_additive_generic
- rolledout:mat_surface_overlay_generic
- rolledout:mat_surface_multiply_generic
- rolledout:mat_surface_default
- rolledout:mat_surface_gravity_surface
- rolledout:mat_surface_ice_surface
- rolledout:mat_surface_sticky_surface
- rolledout:mat_surface_invisible
- rolledout:mat_surface_goal_surface
- Material animations
Example material JSON config¶
This goes in the /materials
array of a stage config. More info can be found on the spec at Material Object.
{
"name": "material_001",
"base_material": "rolledout:mat_surface_translucent_lit_generic",
"animations": [
"anim_simple",
"anim_colors",
"anim_opacity"
],
"parameter_overrides": {
"base_color_texture": {
"type": "texture2d",
"value": "a1_png"
},
"base_color_multiplier": {
"type": "vector3",
"value": { "x": 1.0, "y": 0.8, "z": 1.0 }
},
"opacity": {
"type": "scalar",
"value": 0.8
},
"refraction_texture": {
"type": "texture2d",
"value": "refr_png"
}
}
}