How do I change the color of an item with a laser?

About advanced scenes, and the Thyme scripting language used in Algodoo.

How do I change the color of an item with a laser?

Postby Nickcoww » Sat Jan 13, 2018 5:01 am

I just want to change the color of a shape, circle for example, using a laser, and I was wondering how to do this. Thanks!
Nickcoww
 
Posts: 1
Joined: Sat Jan 13, 2018 4:57 am

Re: How do I change the color of an item with a laser?

Postby Kilinich » Mon Jan 15, 2018 12:10 pm

In laser:

onLaseHit = (e) => {e.geom.color = [0.4,0.4,0.4,1]}
Dream of Algodoo as game development engine...
User avatar
Kilinich
[Best bug reporter 2010]
 
Posts: 2098
Joined: Mon Aug 31, 2009 8:27 pm
Location: South Russia


Return to Thyme scripting

Who is online

Users browsing this forum: No registered users and 3 guests

cron