Please or Register to create posts and topics.

Detecting when a cube lights up

Is there a way to detecting when a cube lights up from being placed on a trigger?
I can't find one, nor a way to detect what skin an object is using.
Thank You,
Sound Logic

What do you mean by "light up"?

I would like to help, but I am not sure what you are looking for.

Reflective cube hit by a laser beam, I suppose.

Edit:
Just found out that a cube has different outputs like OnFizzled, OnPlayerPickup but I didn't found anything like 'being hit by laser' or something. Maybe Skotty can find a solution for your problem...

No, lit up like placed on a button.

As in when the cube's skin changes from light blue (or pink) to yellow?

I don't think there's a way to do that directly, but you can fake it.
Place a small trigger in the center of the button.
Create a filter_activator_class with the class name set to prop_weighted_cube and the filter mode at Allow. Name this.
Go back to the trigger you created and set the filter name to whatever you named the filter_activator_class.

Create an output on the trigger with the output name OnStartTouch. Then, put in whatever you want to happen when the cube changes skins.

Courier6 wrote:
As in when the cube's skin changes from light blue (or pink) to yellow?

I don't think there's a way to do that directly, but you can fake it.
Place a small trigger in the center of the button.
Create a filter_activator_class with the class name set to prop_weighted_cube and the filter mode at Allow. Name this.
Go back to the trigger you created and set the filter name to whatever you named the filter_activator_class.

Create an output on the trigger with the output name OnStartTouch. Then, put in whatever you want to happen when the cube changes skins.

This plus a math_counter so it actually has to be activating the button

Portal 1.5 http://www.moddb.com/mods/portal-15

I would have the button send the output onpressed and check that its not the player.

12 Angry Tests
"I hear voices. But I ignore them and I just carry on killing."

SO as not to confuse the player with a button that only cubes can activate, create a second button with a logic_branch setup OR, make one of those hole-in-the-wall dealies.

Image
PortalStories.com
"Oh, in case you got covered in that repulsion gel, here's some advice the lab boys gave me: DO NOT get covered in the repulsion gel."

I have such a setup in my map, Interception. I use the trigger with the phys_object filter. It works very well.

Would it be possible to simply use the cube-only button rather than the standard circular one? Not totally sure I understand the question, but it sounds to me like you just want a button activated by a cube, and the cube-only button would stop a player from activating it.

There is no "N" in "Turret."