on property changed -> send value

i want to send, when a property change, his value, like that:

property change (prop) - and - message (value=prop)

i know that i need a python script for send the value of a property, but i don’t know python, so, someone can help me? thanks :smiley:

click the T/P button in the message actuator and you can send a property value without python.

I hope it helps

that would be great!!! but can you make a file, cause i don’t think (very probably my fault) that it works? thanks mmuch!

The button is already there.
BUT you need a script to read the body of the message ;).

See messageDemo.blend (136 KB)

I hope it helps

i need to modificate only the object that send, not the object that receive… and in the file i don’t understood how to apply it on my own blend… there is any tutorial, or something…?

I think I got what you want. But this is exactly what you have in your first post already.

property change (prop) - and - message (value=prop)

property change sensor - AND controller - message actuator sending the property value
Three logic bricks.

Or do you mean something else?

i mean exactly that, but i don’t know how to send the value of a property(that ovviously can change), using the T/P button…

Have you ever pressed that button?
You will see that the prefix of the body field changes from Body: to Propertyname:. So you can enter the name of the property.

See the above messageDemo.blend there are two objects. The object Sender is doing exactly what you want.

Note that you can probably (without Python) just use the Property actuator and use the “copy” portion of it.

Hope that helps!


oh my god sam you are a genius!!! thanksssssss!!! that would be very useful for many things, but now i had just to send a message…

monster, watch my file: i already did what you said, but it doesnt work!!! is that the problem!!!

i hope you can find a way to fix the problem… that i dont know that is…


promes2.blend (130 KB)

The problem is that the message actuator is sending the property in the BODY of the message, NOT the subject. Your second object is looking for the subject.

For something as simple as this, the copy property actuator is much better suited… but if you want messages to work like this, you have to use Python to receive the body of the message.

Here’s the (working) blend file.


promes2.blend (36.5 KB)

and how can i send in the subject field the value of the property, so the receiver can not became changed??? thanks