Controlling camera woes... need assistance

Hiya, I've done a google search on this topic and came up with some interesting threads but none have worked so far for me. I've been at this for two nights now and I would love some help.
Here's what I'm trying to do.
- two screens are setup [ | ]
- Player shoots arrow from one side of the screen
- arrow travels and cam follows to other screen
- once the arrow collision is detected send the cam back to it's origin (gradually, not pop back)
I've exhausted every option I can find and currently I created a camFollow boolean which is switching correctly through rules (using display text to debug) and I have a camTracker actor on the stage that's being constrained by the arrow when it spawns. The issue is I can't send the cam back successfully, it appears to stay constrained to the arrow's X.
Any help would be appreciated. Hard to put in words, but any idea/templates I can look at would be appreciated.
thx!
~t
Here's what I'm trying to do.
- two screens are setup [ | ]
- Player shoots arrow from one side of the screen
- arrow travels and cam follows to other screen
- once the arrow collision is detected send the cam back to it's origin (gradually, not pop back)
I've exhausted every option I can find and currently I created a camFollow boolean which is switching correctly through rules (using display text to debug) and I have a camTracker actor on the stage that's being constrained by the arrow when it spawns. The issue is I can't send the cam back successfully, it appears to stay constrained to the arrow's X.
Any help would be appreciated. Hard to put in words, but any idea/templates I can look at would be appreciated.
thx!
~t
Comments
Cheers!
for my game - http://itunes.apple.com/us/app/splatt/id470602397?ls=1&mt=8 - i used scene settings within prototype actors plus a combo of the settings in canon physics to get this to work.
look at camera.origin.x / y within scene properties within your arrow
thx guys.
artic, would you mind putting something quickly together? Just squares and the rules would be awesome. I'm sure it'll be beneficial to others as well.
~t
Also I took a look at the Cannon Physics demo, and it's actually what I currently have which is not very elegant, because once you click to return, the ball is already charging but it snaps back to the origin
~t
thx
~t
Once an actor is constrained, can that constraint be broken?
~t
or. . .
Since the camera is already following the arrow. How about doing the alpha to 0 trick (as described previously). And spawning a new different arrow at the point of impact. This new arrow would look the same but actually have different behaviors in it (sticks to character/wall, and destroys over time.)
So as I stated in another thread I put up a demo demonstrating what we spoke about here.
Search for Beyond the Basics in the New section of the launchpad and it should pop up or go here http://gamesalad.com/game/45386
Getting that fireworks cheer felt good
~t
Here is a suggestion. In the arrow's move rule, replace both the 'rotation' and the 'change attribute (self.rotation)' behaviors with the following behavior:
Constrain Attribute: self.rotation To: vectorToAngle( self.Motion.Linear Velocity.X , self.Motion.Linear Velocity.Y )
This will make the arrow's rotation match its trajectory and fly realistically through the air.
[Edit] Just tried it, and it works like a charm, just what it needed... thx again!
~t