Alice Community  

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

Reply
 
Thread Tools Display Modes
Button Masher
Old
Dragoon
Guest
 
Status:
Posts: n/a
Exclamation Button Masher - 04-20-2011, 08:37 PM

Hello everyone I am currently very puzzled at the moment. Does anybody know how to program a button mashing event? What I mean by button mashing is pressing for example the A key as fast as possible and after it has reached a certain limit proceeds to the next event or so. Picture a video game whereas two swords clash and the player has to press the A key a certain number of times in a time limit to beat the enemy sword or else the other sword beats the player's. An answer for this would be GREATLY helpful and as soon as possible too! Thank you all and have a nice day.

-Dragoon
   
Reply With Quote
Old
jediaction
Senior Member
 
jediaction's Avatar
 
Status: Offline
Posts: 5,064
Join Date: Jul 2009
Location: Bel Air, Maryland
Default 04-20-2011, 09:14 PM

Well, the way I would do it is have a bunch of variables. The numbers would go from 1-15. When the swords clash, when you press space, the numbers would go up, and at the same time, have a method that reads if after 1 second, (in an if/e;se statement) if the variable (15) is not == to 1, then do miss method, or to slow


Website: www.salokingames.com
FaceBook: www.facebook.com/SalokinGames
   
Reply With Quote
Old
Dragoon
Guest
 
Status:
Posts: n/a
Default 04-20-2011, 09:29 PM

Quote:
Originally Posted by jediaction View Post
Well, the way I would do it is have a bunch of variables. The numbers would go from 1-15. When the swords clash, when you press space, the numbers would go up, and at the same time, have a method that reads if after 1 second, (in an if/e;se statement) if the variable (15) is not == to 1, then do miss method, or to slow
You are right without a doubt but I'm still having some trouble. Would there be any sort of way whereas you could possibly create an example for me and I learn with it?
   
Reply With Quote
Old
jediaction
Senior Member
 
jediaction's Avatar
 
Status: Offline
Posts: 5,064
Join Date: Jul 2009
Location: Bel Air, Maryland
Default 04-21-2011, 09:00 AM

If I can, I will, but I have a lot of stuff to finish before friday, and a lot of people in the community have asked me for help and I don't know if I can do everyone. I will try


Website: www.salokingames.com
FaceBook: www.facebook.com/SalokinGames
   
Reply With Quote
Old
sfunk
Senior Member
 
sfunk's Avatar
 
Status: Offline
Posts: 1,112
Join Date: Mar 2011
Location: I don't know
Default 04-21-2011, 02:05 PM

i'll make an example world when i get home today, it will be about 4 or 5 pm when i'll get done with it so you dont have to worry about it jedi.

EDIT: here you go, hope this is what your looking for,
-use arrows to move white penguin close to blue one to commense button mashing madness
Attached Files
File Type: a2w buttonmasherexample.a2w (813.4 KB, 8 views)


If you are stuck on a project, check out the tutorials I made here at this link:

http://alice.org/community/showthread.php?p=36778#post36778

There are lots of tutorials on it so far, including some youtube videos, check it out

Or..

Go to my youtube channel to check out my alice 2.2 tutorials I have there..

http://www.youtube.com/user/sfunk1992?feature=mhsn

Last edited by sfunk; 04-21-2011 at 03:55 PM.
   
Reply With Quote
Old
jediaction
Senior Member
 
jediaction's Avatar
 
Status: Offline
Posts: 5,064
Join Date: Jul 2009
Location: Bel Air, Maryland
Default 04-21-2011, 05:22 PM

Thanks sfunk...


Website: www.salokingames.com
FaceBook: www.facebook.com/SalokinGames
   
Reply With Quote
Old
Dragoon
Guest
 
Status:
Posts: n/a
Default 04-26-2011, 12:49 PM

Quote:
Originally Posted by sfunk View Post
i'll make an example world when i get home today, it will be about 4 or 5 pm when i'll get done with it so you dont have to worry about it jedi.

EDIT: here you go, hope this is what your looking for,
-use arrows to move white penguin close to blue one to commense button mashing madness
Thank you! Your a lifesaver! And thank you too for the interest, jedi.
   
Reply With Quote
Old
Dragoon
Guest
 
Status:
Posts: n/a
Default 04-26-2011, 02:17 PM

this is what i came up with and what i'll implement into my main program! Thanks again!
Attached Files
File Type: a2w Button masher sword example.a2w (494.1 KB, 3 views)
   
Reply With Quote
Old
TauTrumpsPi
Senior Member
 
TauTrumpsPi's Avatar
 
Status: Offline
Posts: 399
Join Date: Mar 2011
Location: The diamond layer
Default 04-26-2011, 02:21 PM

Quote:
Originally Posted by Dragoon View Post
this is what i came up with and what i'll implement into my main program! Thanks again!
I'm getting an error midprogram...


--------------------------------------------------------------------------------------------------------------------------
I have plenty of common sense. I just choose to ignore it.
-Calvin and Hobbes

Wondering about my Avatar?
http://en.wikipedia.org/wiki/Tardigrade

Wondering about my username?
http://www.youtube.com/watch?v=jG7vhMMXagQ
   
Reply With Quote
Old
sfunk
Senior Member
 
sfunk's Avatar
 
Status: Offline
Posts: 1,112
Join Date: Mar 2011
Location: I don't know
Default 04-26-2011, 03:19 PM

Glad to help! It looks pretty promising


If you are stuck on a project, check out the tutorials I made here at this link:

http://alice.org/community/showthread.php?p=36778#post36778

There are lots of tutorials on it so far, including some youtube videos, check it out

Or..

Go to my youtube channel to check out my alice 2.2 tutorials I have there..

http://www.youtube.com/user/sfunk1992?feature=mhsn
   
Reply With Quote
Reply

Tags
button masher, dragoon, helpful, key, sword

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 ©2024, Carnegie Mellon University
Alice 2.x © 1999-2012, Alice 3.x © 2008-2012, Carnegie Mellon University. All rights reserved.