Here is what my code looks like.:
scene =bge.logic.getCurrentScene()
S = cont.actuators['s']
print('now')
scenes = beg.logic.getSceneList()
for scene in scenes:
if scene.name == 'scene':
back = scene.objects['back']
print("here")
if 1==1:
back ['phase'] =2
print('baby')
S.activate
The only printed command is 'here' and I get an error that says I referenced 'back' before I assigned it. I'm trying to change a property called 'phase' that is on an object called 'back'. 'S' is an actuator that ends the overlay scene that the python running object called 'cube' is on. The scene is already loaded so that is not the problem. I'm just not sure where to go from here.
beg
is an undefined name (you probably meanbge
), andIf
shouldn't be written with a captial letter. Take the time to create an example that actually works, if you want other people to spend time helping. $\endgroup$