EMS Forums
Please login or signup to post on the forums.

Join the forum, it's quick and easy

EMS Forums
Please login or signup to post on the forums.
EMS Forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Two questions

2 posters

Go down

Two questions Empty Two questions

Post by Joegernaut Thu Apr 28, 2011 11:56 pm

Firstly, I'd like to make a status bar at the bottom of the view that follows the screen. It'll have objects that will become visible when a global.variable is set to true.
eg. You collect a letter it shows you which letters you have.

I'm doing it without drawing, just an object with a sprite

Secondly, I'd like to make the player have pink particles come off it when they move.

Joe
Joegernaut
Joegernaut
Corporal
Corporal

Posts : 78
Join date : 2011-04-18
Age : 27
Location : New Zealand

Back to top Go down

Two questions Empty Re: Two questions

Post by Water Chicken Fri Apr 29, 2011 12:00 am

Okay, for the first I suggest:
Code:

if global.VAR = true{draw_sprite(SPRITE,0,view_xview+XPOSITION,view_yview+view_hview-SPRITE_WIDTH)}
Repeat that for how ever many sprites you have.
I'll move onto the next question when this one is solved.
Water Chicken
Water Chicken
Lieutenant
Lieutenant

Posts : 254
Join date : 2011-03-22
Age : 24
Location : Chandler, Indiana

Back to top Go down

Two questions Empty Re: Two questions

Post by Joegernaut Fri Apr 29, 2011 12:03 am

but then how do I make the sprite change if a variable is activated
Joegernaut
Joegernaut
Corporal
Corporal

Posts : 78
Join date : 2011-04-18
Age : 27
Location : New Zealand

Back to top Go down

Two questions Empty Re: Two questions

Post by Water Chicken Fri Apr 29, 2011 12:14 am

draw_sprite(SPRITE,global.VARIABLE,view_xview+XPOSITION,view_yview+view_hview-SPRITEWIDTH)
If global.VARIABLE is true, it will draw it as a different subimage.
Water Chicken
Water Chicken
Lieutenant
Lieutenant

Posts : 254
Join date : 2011-03-22
Age : 24
Location : Chandler, Indiana

Back to top Go down

Two questions Empty Re: Two questions

Post by Joegernaut Fri Apr 29, 2011 12:21 am

Mah epics diagramz

Two questions Diagra10

The grey letters means you haven't gotten it yet and pink means you have
Joegernaut
Joegernaut
Corporal
Corporal

Posts : 78
Join date : 2011-04-18
Age : 27
Location : New Zealand

Back to top Go down

Two questions Empty Re: Two questions

Post by Water Chicken Fri Apr 29, 2011 12:24 am

For the letters:
Code:
draw_sprite(LETTERSPRITE,global.HASGOTTHAT,view_xview+XPOSITION,view_yview+YPOSITION)
Change LETTERSPRITE to the sprite of the letter, HASGOTTHAT to the variable that tells you if you've gotten that powerup or not, XPOSITION to the x position on screen, and same for YPOSITION.
Water Chicken
Water Chicken
Lieutenant
Lieutenant

Posts : 254
Join date : 2011-03-22
Age : 24
Location : Chandler, Indiana

Back to top Go down

Two questions Empty Re: Two questions

Post by Sponsored content


Sponsored content


Back to top Go down

Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum