When my ball hits either looseStick OR looseStick2 the same message appears, I can do this by copy/pasting the same function. It would be better and cleaner if I could simply make an OR conditional for looseStick2.
For example I can't find a way to say:
ball (On collision WITH (looseStick) OR (looseStick2)) { DO STUFF }
Screenshot:
<img src="http://img832.imageshack.us/img832/3051/45729705.png" border="0" />
Does this Plug-In help you?
OR-Plug-In
There is a third party plugin located at: scirra.com/forum/plugin-or_topic47046_post294591.html
This will give you your OR statement
My way would be without a Plugin
ball On collision WITH (looseStick) set variableA to x
ball On collision WITH (looseStick2) set variableA to x
variableA = x { DO STUFF }
vidi, that's not a bad idea, since I might make more than two looseSticks later on. OR only works for two objects. Thanks Weishaupt and smitchell I will try the OR plugin as well.
vivi I have a problem with your example, if the ball collides again LooseVar won't work, or won't do anything. Is there a way to wait (allow the ball to bounce) and reset the LooseVar?
<img src="http://img593.imageshack.us/img593/663/loosevar.png" border="0" />
if loseVar=0 do another stuff .eg. make it visible again and maybe set x and y to another location ...
I understand now, Thanks!
For some reason the animation for looseVar won't start, take a look.
<img src="http://img546.imageshack.us/img546/5176/loosevarnoanimation.png" border="0">
<img src="http://img706.imageshack.us/img706/7330/animationo.png" border="0">
Download Project: Lucky Hit Capx
I think Families will help for things like this.
alspal can you explain further?
take a look.
I'm sorry,I can not open your capx,because You use the "or" plugin
Plugins are not allowed for the arcade here, therefore I do not install third-party plugins
btw families are not yet in construct2
vidi I removed the OR plugin, check back again.
HERE
Develop games in your browser. Powerful, performant & highly capable.
First of all - Nice graphics
It looks like you, just like me, have been stumbling over the strange behavior of "Wait"...
Try this:
<img src="http://quak.laurig.de/tryagain.JPG" border="0" />
...and set your animation to LOOP
Weishaupt that's it!
Thanks!!