User Tools

Site Tools


developer_editor:script:setshapecolor

setShapeColor

  • Parameters & Types:
    • shapeid:number
    • r:number
    • g:number
  • b:number
  • Return value and type:
    • ErrorCode. OK
  • The main purpose of this method is to set the shape color
  • Specific use cases are as follows:
--Set the shape with id 1 to black
--The first parameter is the shape id
--The last three parameters are the colors to be changed, which are R, G, B (red, green, and blue)
MapMark:setShapeColor(1,0,0,0)
--Display in the chat box
Chat:sendSystemMsg("The shape with id 1 is set to black!")
developer_editor/script/setshapecolor.txt · Last modified: 2024/06/18 02:05 by don