So I am assuming you want to be able to make something like this?
http://pekkasandborg.com/portfolio/?id=2
Well that is just made using multiple sprites tied together. (by putting several sprites into one sprite)
Offline
While that is an excellent example of what I mean that's probably not what I would do with it. I'm a spaceopera fanatic, so if this becomes a feature expect games where you controll huge space ships with loads of turrets!
Offline
AlveKatt wrote:
While that is an excellent example of what I mean that's probably not what I would do with it. I'm a spaceopera fanatic, so if this becomes a feature expect games where you controll huge space ships with loads of turrets!
You could still make a turret follow a ship. Just don't expect it to move perfectly in sync with the ship. Also how a "turret" is normally done is not with multiple rotation points but by putting several sprites into a single sprite.
Offline
archmage wrote:
You could still make a turret follow a ship. Just don't expect it to move perfectly in sync with the ship. Also how a "turret" is normally done is not with multiple rotation points but by putting several sprites into a single sprite.
Can you make sprites that have many sprites in Scratch?
How can I make a turret follow a ship? I know how to do it if I settle for the turret being at the rotation point. But how if I want it off set from there?
Offline
Just make a variable called shipx and shipy which are the x and y co-ordinates of the ship.
Then on the turret put:
when flag clicked
forever
go to x (shipx + #how much you want x to move) y (shipy+ #how much you want y to move)
PS: and no you can't put sprites inside sprites in scratch.
Last edited by archmage (2007-08-18 10:29:38)
Offline
AlveKatt wrote:
Aaah. That would work until the ship turns, right?
Yes.
Offline
That's why extra rotation points would be nice. Then you can have sprites stick to another sprite and keep their position on the other sprite even if it changes direction while still pointing in the direction you want it to point.
Offline
What would solve this problem (and others) would be a "rotate around" command.
Rotate (x) degrees (left/right) around point (x), (y).
So when you turret turns you use normal rotate, when the ship turns, you rotate the turret an equal amount around the ships current x/y coordinate.
This would also make rotational scrolling scenary possible - ie where when you turn left, the vehicle sprite stays still but the scenary rotates around it to the right, giving the illusion of a turn.
Offline