saving

Non-platform specific questions.

saving

Postby Zehper48 » Fri Dec 08, 2006 9:31 pm

If i made a button inside my game and if you click on it, it saves the x and y corrdinates and a health number, what would be the code for that, and how do you find the x and y corrdinates in the game?
I like score
User avatar
Zehper48
 
Posts: 241
Joined: Sun Jun 11, 2006 1:34 am
Location: Advanced Noob
Score: 4 Give a positive score

Postby Troodon » Sat Dec 09, 2006 7:26 am

Well...getting coordinates is pretty easy. Make a text actor "xactor" and write in it's draw actor -> script editor:

xactor.textNumber = youractor.x

Then make another text actor "yactor" and write:

yactor.textNumber = youractor.y

Then just make how you want the text actors to display in key down event.
You can use for example: create actor, change transparency, change z depth, etc etc. One which fits with your game.
I can't die, I already tried
~on the forums since GE 1.3.3~
User avatar
Troodon
 
Posts: 1539
Joined: Thu Jan 12, 2006 3:29 pm
Location: HELL
Score: 56 Give a positive score

Postby Zehper48 » Sun Dec 10, 2006 6:39 pm

thanks man it works!
I like score
User avatar
Zehper48
 
Posts: 241
Joined: Sun Jun 11, 2006 1:34 am
Location: Advanced Noob
Score: 4 Give a positive score

Postby Troodon » Mon Dec 11, 2006 7:13 pm

No problem. :)
I can't die, I already tried
~on the forums since GE 1.3.3~
User avatar
Troodon
 
Posts: 1539
Joined: Thu Jan 12, 2006 3:29 pm
Location: HELL
Score: 56 Give a positive score


Return to General

Who is online

Users browsing this forum: No registered users and 1 guest