sim.setShapecolor,

Typically: "How do I... ", "How can I... " questions
Post Reply
Sophia
Posts: 12
Joined: 31 Oct 2019, 06:33

sim.setShapecolor,

Post by Sophia » 12 Nov 2019, 03:02

can i change the floor's color by function? i have tried the function sim.setShapecolor, it can only change the object's color but floor.i hope changinng the color of the floor that robot passed by,so what function i can use?

fferri
Posts: 440
Joined: 09 Sep 2013, 19:28

Re: sim.setShapecolor,

Post by fferri » 12 Nov 2019, 08:34

You can add a drawing object with sim.addDrawingObject and fill with items via sim.addDrawingObjectItem as the robot passes around.

Check also what types of drawing objects you can add.

coppelia
Site Admin
Posts: 7450
Joined: 14 Dec 2012, 00:25

Re: sim.setShapecolor,

Post by coppelia » 13 Nov 2019, 17:01

Have also a look at the demo model Models/robots/mobile/lumibot.ttm that does exactly what you want (but with a color gradient).

Cheers

Post Reply