Alice Community  

Go Back   Alice Community > Alice 2 > How do I...?

Reply
 
Thread Tools Display Modes
How do I add levels to a game program?
Old
caitlindlc
Junior Member
 
Status: Offline
Posts: 5
Join Date: Jan 2012
Default How do I add levels to a game program? - 01-06-2012, 11:52 AM

My game is called Eat the Hay. In the game, the user controls a cow that moves to bales of hay to "eat" it. (The bales actually just disappear when the cow is near enough). This is for a school project, but I have to make this game more difficult. I wanted to add two levels and make each level progressively harder. However, I have no idea how to even add levels and how to go about it. I've attached the game, but I really need help!
Attached Files
File Type: a2w eat the hay.a2w (3.69 MB, 4 views)
   
Reply With Quote
Old
GameKid
Senior Member
 
GameKid's Avatar
 
Status: Offline
Posts: 467
Join Date: May 2011
Location: My magnificent castle
Default 01-06-2012, 09:35 PM

Add a rally where the cow starts, and multiple invisible hays with booleans. Make it so that when the cow eats all the current hays, he moves back to the rally, and the invisible hays appear and set the boolean to true. Also make it so that the cow will only eat the hay if the booleans are true.
Build off of that setup. Private message me if you need more guidance.


[COLOR=e4eaf2]Your text here[/COLOR]
Come on, you know you want to try it.
   
Reply With Quote
Old
jwags
Junior Member
 
Status: Offline
Posts: 12
Join Date: Sep 2011
Location: brotherwags@aol.com
Default 01-12-2012, 10:14 PM

exactley what he said but in english ---/\


open a blank map. go really far left facing one way, add opject then click the tab that says "more controls" then click "drop dummy object at camera", now go backwards a lot and turn the opposite way (should face away). and drop a camera dummy object here.

now move camera to the first dummy object (right click camera -> click "move to" -> select "dummy object 1" (might be in a folder))

now build your seen one. then do the same thing near "dummy object 2" but harder i guess.

now loop infinity times a world level method in the main method. Now create a world level function and make an if statement in there, and drag a world level function in that says "both a and b". and drag it into b multiple times till you have enough for all the object of hay in the first level. then drag an "==" in each value. and make it equal to "false". then drag each hay properties "is showing" in the values of a and b all the way through till there are no more hay bales left uncalled and no values left. (should be "both [hay1] [isShowing] == [false] and hay2...")
(only do the bales that are for level 1) and make sue the functioni s a boolean

then return true in the first "do nothing" then return false in the "else". then call the function in the method u made be4 in an if statement. and then move camera and guy to camera dummy object 2 from be4. duration of 0. and yea u got the point
   
Reply With Quote
Old
caitlindlc
Junior Member
 
Status: Offline
Posts: 5
Join Date: Jan 2012
Default 01-17-2012, 11:51 AM

So basically i've reworded a section of what you said into a step by step list:

1. loop infinity times a world level method in the main method

2. create a world level function and make an if statement in there

3. drag a world level function that says "both a and b"

4. drag it into b multiple times till you have enough for all the object of hay in the first level

5. drag an "==" in each value. and make it equal to false

6. drag each hay properties "is showing" in the values of a and b all the way through till there are no more hay bales left uncalled and novalues left
(should be "both [hay1] [isShowing] == [false and hay2...")

7. then return true in the first "do nothing" then return false in the "else."

8. call the function in the method you made before in an "if statement"

9. move the camera and guy to camera dummy object 2 from before, duration of 0

But I don't understand step 4. Drag what into b? I might have more questions as I progress through this project. Thank you so much for all of your help!!
   
Reply With Quote
Old
dakota95
Senior Member
 
dakota95's Avatar
 
Status: Offline
Posts: 426
Join Date: Aug 2011
Location: like I would tell you. ;)
Default 01-17-2012, 12:33 PM

the way that I would do this is, and I know there are better ways. But I'd make another "ground" and move it up 1000meters and make it so that if the cow eats all of the hay in the lower world' then move up to a dummy object in upper world


<Insert_Signature_Here>
   
Reply With Quote
Old
caitlindlc
Junior Member
 
Status: Offline
Posts: 5
Join Date: Jan 2012
Default 01-17-2012, 06:39 PM

@dakota95 that sounds like a good idea. But how would I go about making the game program automatically advance to the 2nd level dummy after the hay bales in level one have disappeared?
   
Reply With Quote
Reply

Tags
games, how do i, level, levels, tutorial

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



Copyright ©2020, Carnegie Mellon University
Alice 2.x 1999-2012, Alice 3.x 2008-2012, Carnegie Mellon University. All rights reserved.