Some beginer questions

Non-platform specific questions.

Some beginer questions

Postby Kuraudo-sama » Fri Aug 24, 2007 5:19 am

My first question is; when I try to add a background it covers my player, how do I get around this?

How exactly do I use the "loadGame" function?

How do you make a pause menu?

How do I keep the screen following my actor when walking?

Is there some way to see what I'm pressing? Like when enter is pressed it say "Enter is pressed".

How do I make it fade in fade out.
Kuraudo-sama
 
Posts: 12
Joined: Wed Jul 25, 2007 4:42 am
Score: 1 Give a positive score

Re: Some beginer questions

Postby Jay S. » Fri Aug 24, 2007 1:59 pm

I can answer some of them... :wink:

Kuraudo-sama wrote:when I try to add a background it covers my player, how do I get around this?

Decrease the Z depth of the background. There's a slider near the upper part of the Actor Control window that adjusts this. (Actors with a greater Z Depth appear over other actors.)

Kuraudo-sama wrote:How exactly do I use the "loadGame" function?

Code: Select all
LoadGame("Game.ged");

where "Game.ged" is the name of the game file you want to load. :)

Kuraudo-sama wrote:How do I keep the screen following my actor when walking?

Make your player actor your view's parent. Select the view actor, then on the Actor Control window, you will see a button with "no parent" on it. Click on this, then from the list of actors, choose your player.

Kuraudo-sama wrote:Is there some way to see what I'm pressing? Like when enter is pressed it say "Enter is pressed".

For a text actor, create a Key Down event, and press the Enter key. Then in the Actions list select Set Text. Type the text you want the actor to change to, then select Immediate Action. Now, if you want the text to change when the Enter key is released, choose a Key Up event and press Enter. Then in Actions select Set Text again and type the text you want.

Kuraudo-sama wrote:How do I make it fade in fade out.

Create an actor that is solid black that would cover your whole view actor. Then in a Draw Actor event you could put in Script Editor:
Code: Select all
transp+=0.1;

(The higher the number you put the faster it will fade out.) Now for a fade in, put
Code: Select all
transp-=0.1;

Have any more questions? :)
User avatar
Jay S.
 
Posts: 118
Joined: Thu Apr 26, 2007 6:51 pm
Location: My computer desk. :P
Score: 9 Give a positive score

Re: Some beginer questions

Postby J Maker » Fri Aug 24, 2007 2:10 pm

Kuraudo-sama wrote:My first question is; when I try to add a background it covers my player, how do I get around this?

How exactly do I use the "loadGame" function?

How do you make a pause menu?

How do I keep the screen following my actor when walking?

Is there some way to see what I'm pressing? Like when enter is pressed it say "Enter is pressed".

How do I make it fade in fade out.

for the background change the z-depth lower then your player and use this and DO NOT parent the background to anything
Code: Select all
xscreen = view.xscreen + view.width/2.0;
yscreen = view.yscreen + view.height/2.0;
put this in your backgrounds draw actor. then use this for a veiw draw actor
Code: Select all
double weight = 10;
x = ((weight  - 1)*x + (player.x - width/2))/weight;
y = ((weight  - 1)*y + (player.y - height/2))/weight;
for the enter thing, here's a demo
Attachments
key down demo.zip
here u go
(11.03 KiB) Downloaded 105 times
Some people believe Chuck Norris evolved from a dinosaur, the Chucknorisaurus.
----------------------------------------------------------------------------------
Chuck Norris doesn't sleep, he waits.
----------------------------------------------------------------------------------
Chuck Norris doesn't hunt, he kills.
----------------------------------------------------------------------------------
Chuck Norris once shot down a german fighter plane with his finger by yelling BANG!!!
----------------------------------------------------------------------------------
User avatar
J Maker
 
Posts: 177
Joined: Fri Jun 22, 2007 4:17 pm
Location: in the stick version of Hyrule
Score: 10 Give a positive score


Return to General

Who is online

Users browsing this forum: No registered users and 1 guest

cron