Language Halo Script
(Prints)
Date: | 07/12/07 |
Author: | Bacon |
URL: | http://home.oasis-games.com |
Comments: | 2 |
Info: | n/a |
Score: | (2.95 in 20 votes) |
(global real bottles 99) (script continuous drinkBeer (if (> bottles 1) (begin (inspect bottles) (print "bottles of beer on the wall!") (inspect bottles) (print "bottles of beer!") (print "Take one down, pass it around") (set bottles (- bottles 1)) (inspect bottles) (print "bottles of beer on the wall!") (print " ") ) ) (if (= bottles 1) (begin (print "One bottle of beer on the wall") (print "One last bottle of beer!") (print "Take it down, pass it around") (print "No more bottles of beer on the wall!") (print " ") (print "No bottles of beer on the wall") (print "No more bottles of beer!") (print "Go to the store, buy some more") (print "99 bottles of beer on the wall!") (set bottles -1) (print " ") ) ) )
Download Source | Write Comment
Download Source | Write Comment
Add Comment
Please provide a value for the fields Name,
Comment and Security Code.
This is a gravatar-friendly website.
E-mail addresses will never be shown.
Enter your e-mail address to use your gravatar.
Please don't post large portions of code here! Use the form to submit new examples or updates instead!
Comments
TJ said on 07/21/07 00:36:20
Very nice. I don't have much experience In halo scripts, but that seems like it would work.
Scotty said on 03/13/09 09:17:26
I agree that's nice. I like the approach of hard-coding the 1 bottle and no bottle lines rather than having logic to deal with them. Nice and simple gets my vote every time.