Cannon halfmoon powermeter HELP
kajuto
Member Posts: 314
Hi there everyone!! recently i made my game a cannon for a shooter game, but i made the power meter like in the tutorial, but the power meter is a usual one, a vertical rectangle that the power going up or down. I want to make the power meter like a shape of the moon and the power keep inside that actor when i press the cannon to fire, i post the code here..Help
CANNON CODE : 1) https://www.dropbox.com/sh/pv2oj6v3jlumoqs/GOWU6__0OX
startTime = real, startY = real, loading: boolean
rule : when touch is pressed
-change att- self.loading to true
-change at- self.startTime to self.Time
-constrain att- game.Power to min(2,self.time-self.startTime)
-rotate to position- position : max(game.mouse.positionX,self.positionX) & max(game.mouse.positionY, self.PositionY & speed -150 y relative to scene.
-change att- game.totalshotcam to game.totalshotcam+1
after for 0.1seconds i press a control camera
rule: when mouse button is up
att self.Loading to true
-change att- gamedotindex to 1
-timer: for 4 s respawn actor
- att.self self. loading to false
-att game.how.many loading < 3
- spawn ball actor
Group:
-accelerate: direction 90 degree, relative to scene , acceleration: 150
-change att: self.Start to self.Positino Y
-contrain att: selfPosition Y selft.Start
POWER:
Group of behavior
-constrain att: self.Size.Height to 158*game.Power
-constrain att: self.PositionY to self.SizeHeight/2
photo of the concept (sorry i didn't have my wacom) =-(
i appreciatted it
CANNON CODE : 1) https://www.dropbox.com/sh/pv2oj6v3jlumoqs/GOWU6__0OX
startTime = real, startY = real, loading: boolean
rule : when touch is pressed
-change att- self.loading to true
-change at- self.startTime to self.Time
-constrain att- game.Power to min(2,self.time-self.startTime)
-rotate to position- position : max(game.mouse.positionX,self.positionX) & max(game.mouse.positionY, self.PositionY & speed -150 y relative to scene.
-change att- game.totalshotcam to game.totalshotcam+1
after for 0.1seconds i press a control camera
rule: when mouse button is up
att self.Loading to true
-change att- gamedotindex to 1
-timer: for 4 s respawn actor
- att.self self. loading to false
-att game.how.many loading < 3
- spawn ball actor
Group:
-accelerate: direction 90 degree, relative to scene , acceleration: 150
-change att: self.Start to self.Positino Y
-contrain att: selfPosition Y selft.Start
POWER:
Group of behavior
-constrain att: self.Size.Height to 158*game.Power
-constrain att: self.PositionY to self.SizeHeight/2
photo of the concept (sorry i didn't have my wacom) =-(
i appreciatted it
Best Answer
-
tatiang Posts: 11,949You need to upload your images to a file server such as DropBox, ImageShack, etc. and then post the URL to the uploaded file.
If you want to embed the image, use <*img src="url"> without the *. I have noticed that if you use DropBox, you have to share the images from the Public folder rather than from some other folder in your account. Not sure why.New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
Answers
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
http://www.mediafire.com/download.php?fbhgcy72mtlvk83
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
@tatiang -- thanks! The hard part was drawing the arc. I have absolutely no graphic design skills. (It took 30 minutes to figure out how to cut a circle in half in illustrator!)
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User