User Tools

Site Tools


dragengine:modules:dragonscript:behavior_customcolor

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
dragengine:modules:dragonscript:behavior_customcolor [2020/12/20 22:39] – created dragonlorddragengine:modules:dragonscript:behavior_customcolor [2024/03/14 16:54] (current) dragonlord
Line 8: Line 8:
  
 ====== ECBehaviorCustomColor ====== ====== ECBehaviorCustomColor ======
- 
-Behavior element behavior adding custom color support. 
- 
-Custom colors are typically used to allow players to customize the look of their player actor by altering the color of individual body parts. This behavior allows to define custom color slots the player or artist can manipulate. This behavior does not define how custom colors are applied. This is left for other behaviors or game scripts to do. 
- 
-Custom colors compose of a display name and the currently assigned color. This color can be null to use the assigned default color. An optional list of colors can be used to restrict the colors the player can select. If the list is empty the player can choose the color unrestricted. In addition a display description can be added in case the game developer would like to communicate additional information about the custom color. 
  
 <WRAP center 100%> <WRAP center 100%>
 <WRAP center box 450px> <WRAP center box 450px>
-{{youtube>BbP-lMrr0tQ?medium}}+{{youtube>Gte74Jte8A0?medium}}
 <WRAP centeralign>Behavior in action</WRAP> <WRAP centeralign>Behavior in action</WRAP>
 </WRAP> </WRAP>
 </WRAP> </WRAP>
 +
 +Behavior element behavior adding custom color support.
 +
 +Custom colors are typically used to allow players to customize the look of their player actor by altering the color of individual body parts. This behavior allows to define custom color slots the player or artist can manipulate. This behavior does not define how custom colors are applied. This is left for other behaviors or game scripts to do.
 +
 +Custom colors compose of a display name and the currently assigned color. This color can be null to use the assigned default color. An optional list of colors can be used to restrict the colors the player can select. If the list is empty the player can choose the color unrestricted. In addition a display description can be added in case the game developer would like to communicate additional information about the custom color.
  
 ====== Instance Counts ====== ====== Instance Counts ======
-This behavior can be used multiple times on an element to add different interaction prompts. Use the behavior identifier to tell them apart.+This behavior can be used multiple times on an element to add multiple custom colors to mainpulate. Use the behavior identifier to tell them apart.
  
 ====== Element Class Properties ====== ====== Element Class Properties ======
Line 90: Line 90:
 ====== API Documentation ====== ====== API Documentation ======
  
-[[https://developer.dragondreams.ch/docs/dragonscript/scriptapi/latest/classDragengine_1_1Scenery_1_1ECBehaviorCustomColor.html|ECBehaviorCustomcolor]].+#@LinkApiDocDEDS2_HTML~classDragengine_1_1Scenery_1_1ECBehaviorCustomColor.html,ECBehaviorCustomcolor~@#.
  
 Since DragonScript Module Version **1.5** Since DragonScript Module Version **1.5**
Line 111: Line 111:
 end end
 </code> </code>
 +
 +====== Live Examples ======
 +
 +  * [[https://github.com/LordOfDragons/deexamples|DEExamples Repository]]: Element class adding 5 custom color slots to a box model. Player can interact with box to bring up a dialog to change the colors.
 +    * [[https://github.com/LordOfDragons/deexamples/blob/master/exampleApp/data/scripts/CustomColorExampleClass.ds|CustomColorExampleClass.ds]]. Element class using 5 color slots
 +    * [[https://github.com/LordOfDragons/deexamples/blob/master/exampleApp/data/scripts/PlayerActionCustomColor.ds|PlayerActionCustomColor.ds]]. Player action showing dialog to select color.
 +    * [[https://github.com/LordOfDragons/deexamples/tree/master/exampleApp/data/content/models/customColor|customColor]]. Directory containing images to define the locations on the skin where each individual color applies to.
  
dragengine/modules/dragonscript/behavior_customcolor.1608503967.txt.gz · Last modified: 2020/12/20 22:39 by dragonlord