python question

I need help with a python script. I want to know how do you get a property to activate an actuator using script? I tired this but it didnt work. Could someone please help. I will find so much use for this. thanks

cont = GameLogic.getCurrentController()
own = cont.owner

if own[“prop”] == (1):

Try this:

cont = GameLogic.getCurrentController()
own = cont.owner

my_act = cont.actuators["act"]

if own["prop"] == 1:

check the console. I think you will find an error there because GameLogic.addActiveActuator expects 2 parameters see

As this is deprecated use

I hope it helps

You use the cont.activate function.

c = GameLogic.getCurrentController()
o = c.owner

if o['prop'] == 1:

thank you for helping. I used both your scripts to get it done. Now i have controll over what would have been a mess of noodles.