It is currently Thu Dec 03, 2009 3:18 am
All times are UTC


Welcome
Welcome to <strong>PresStart</strong>.
[url=http://presstart.freeforums.org/profile.php?mode=register]Join[/url] PresStart today!


Post new topic Reply to topic  [ 10 posts ] 
Author Message
 Post subject: Tutorial: Limited Cheat Codes (Easy/intermediate,GML used)
PostPosted: Thu Jul 17, 2008 8:22 am 
Offline
DYNOMITE!
User avatar

Joined: Thu Jul 03, 2008 8:10 am
Posts: 39
Location: USA
This tutorial will show you how to make limited cheat codes (a cheat code that will stop working if you put it in too many times).

Simply create the events and add the GML codes in the events. Put this in a "main" object. (If you don't know. A main is an object that has no sprite. Its only purpose is to set variable to complete a task in a room.)

Create Event
global.code1=0;
global.code2=0;
global.code3=0;
//this sets our limiting variables so that nobody goes past the limit

Any Key Press Event or something else
global.code=get_string("Please enter code","");
//asks the player to enter a code
{{
if (global.code="hey" && global.code1 < 3)
//if the person enters hey as the code and our limit var is less than 3
{
lives+=2;
//add two lives
sound_play(good_code);
//play a sound
global.code1+=1;
//raise the limit
}
else
if (global.code="ok" && global.code2 < 1)
//if the person enters ok as the code and our limit var is less than 1
{
health=100;
//set our health to 100
sound_play(good_code);
//play a sound
global.code2+=1;
//raise the limit
}
else
if (global.code="score" && global.code3 < 5)
//if the person enters score as the code and our limit var is less than 5
{
score+=50;
//add 50 points to the score
sound_play(good_code);
//play a sound
global.code3+=1;
//raise the limit
}
else
{
show_message("Too Bad")
//if the player did not enter any of the above codes show a message that says Too Bad
}}}




If you have any questions please post them below and I don't ask for any credit for this. Also, I hope you come up with better cheat codes than I did! :lol:

_________________
I am an Image in the Game Maker Quiz!

{Insert Clever Sentence Here}


Last edited by VGCLeader on Fri Jul 18, 2008 5:10 am, edited 2 times in total.

Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 17, 2008 10:46 pm 
Offline
The PresStart Admin Counsel

Joined: Thu Jan 31, 2008 1:48 am
Posts: 107
... bragger

No I'm joking! That's kind of cool... show off

lol I'm messing with you. Thanks for the tip! We'll give it a go sometime :)

_________________
Where the fun is at!
http://www.presstartpro.com/


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jul 18, 2008 4:23 am 
Offline
DYNOMITE!
User avatar

Joined: Thu Jul 03, 2008 8:10 am
Posts: 39
Location: USA
Could a mod please move this topic into the tutorials section? Also, I'm not bragging.

Download Maze Man: VGC Version Here:
http://www.vgcommand.com/?page_id=13
See how great it is? And we have even better games coming. This game is terrible compared to our next game coming out.


Now I'm bragging.

_________________
I am an Image in the Game Maker Quiz!

{Insert Clever Sentence Here}


Top
 Profile  
 
 Post subject:
PostPosted: Sat Jul 19, 2008 12:48 am 
Offline
The PresStart Admin Counsel

Joined: Thu Jan 31, 2008 1:48 am
Posts: 107
You don't need to worry about moving it. This spot if fine, but you can copy it if you are worried about it!

_________________
Where the fun is at!
http://www.presstartpro.com/


Top
 Profile  
 
 Post subject:
PostPosted: Sat Jul 19, 2008 5:07 am 
Offline
DYNOMITE!
User avatar

Joined: Thu Jul 03, 2008 8:10 am
Posts: 39
Location: USA
I find it funny that my rank is "lolnoob". How many post do you need to get to a second rank? Is there a rank list posting anywhere around here? I didn't see one.

_________________
I am an Image in the Game Maker Quiz!

{Insert Clever Sentence Here}


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 21, 2008 10:08 pm 
Offline
The PresStart Admin Counsel

Joined: Thu Jan 31, 2008 1:48 am
Posts: 107
You need 20 posts. I'm sorry we didn't post it. You can now find a sticky called "ranks" under rules and regulations! Thank you for pointing out this problem!

_________________
Where the fun is at!
http://www.presstartpro.com/


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jul 23, 2008 6:39 am 
Offline
DYNOMITE!
User avatar

Joined: Thu Jul 03, 2008 8:10 am
Posts: 39
Location: USA
Any time :)

_________________
I am an Image in the Game Maker Quiz!

{Insert Clever Sentence Here}


Top
 Profile  
 
 Post subject:
PostPosted: Sun Oct 05, 2008 8:27 pm 
Offline
The PresStart Admin Counsel

Joined: Thu Jan 31, 2008 1:48 am
Posts: 107
I didn't come up with the ranks by the way lol!

_________________
Where the fun is at!
http://www.presstartpro.com/


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 13, 2009 1:30 am 
Offline
THE MEMBER IS ONLY THE BEGINNER
User avatar

Joined: Mon Jul 13, 2009 12:49 am
Posts: 5
Location: Australia
Hey, thanks VGCLeader.
I've been looking for this code for ages!

_________________
Need a website? Help me fill my portfolio by emailing/pm me a drawing of what you want. FREE OF CHARGE


Top
 Profile  
 
 Post subject:
PostPosted: Sat Jul 18, 2009 4:09 am 
Offline
The PresStart Admin Counsel

Joined: Thu Jan 31, 2008 1:48 am
Posts: 107
If you need help with code, don't be afraid to post in the help section :)

_________________
Where the fun is at!
http://www.presstartpro.com/


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 10 posts ] 

It is currently Thu Dec 03, 2009 3:18 am
All times are UTC

Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

  

cron