Guest User

Untitled

a guest
Jul 16th, 2018
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.15 KB | None | 0 0
  1. module Basic #basic commands where there isn't a direct room interaction
  2.  
  3.  
  4. def do_help
  5. send " BABY SEAL MUD COMMANDS"
  6. send " say: just type say and your message"
  7. send " Look: examine your immediate surroundings."
  8. send " exit: leave the game"
  9. send " help: what you're looking at right now."
  10. send " Bounce: makes magic bubblegum. also how you move."
  11. send " Flop: for resting and chewing bubblegum."
  12. send " Get: pick up magic bubblegum."
  13. send " Chew: prepare for magic! precurser to blow."
  14. send " Blow: make powerful tools to aid you!"
  15. send " Take: picks up the most recent item you made."
  16. send " Inventory: examine your inventory."
  17. send " Wear: wield that magic!"
  18. send " Remove: un-wield that magic!"
  19. send " Drop: you drop a magic item on the ground."
  20. send " glue: glue two objects together. note- if you have three or more objects in your inventory, you'll lose them."
  21. send " Capitalized commands have shortcuts, the first letter of the command. l for look, w for wear, and so on. note: b = bounce, bb = blow bubble"
  22. end
  23.  
  24. def do_flop
  25. send "You grunt adorably as you flop down on the ground to rest."
  26. other_players.each { |p| p.send "#{name} flops down onto the ground with an adorable little grunt."}
  27. @position = true
  28. end
  29.  
  30. def do_wear
  31. if @inv.empty?
  32. send "Your inventory is empty."
  33. else
  34. send "You carefully balance a #{@inv.last.itemcolor} #{@inv.last.itemname} on your head."
  35. other_players.each { |p| p.send "#{name} carefully balances a #{@inv.last.itemcolor} #{@inv.last.itemname} on his head. "}
  36. @wear.push(@inv.pop)
  37. end
  38. end
  39.  
  40. def do_remove
  41. if @wear.empty?
  42. send "You aren't wearing anything to remove."
  43. else
  44. send "You remove a #{@wear.last.itemcolor} #{@wear.last.itemname} from your head. "
  45. other_players.each { |p| p.send "#{name} removes a #{@wear.last.itemcolor} #{@wear.last.itemname} from his head. "}
  46. @inv.push(@wear.pop)
  47. end
  48. end
  49.  
  50. def do_chew
  51. unless @position
  52. send "One cannot chew gum and bounce at the same time."
  53. return
  54. end
  55. if @inventorybg > 0
  56. send "You begin chewing one of your magic pieces of bubblegum."
  57. other_players.each { |p| p.send "#{name} begins chewing a piece of magic bubblegum."}
  58. @inventorybg -= 1
  59. @readytoblow = true
  60. else
  61. send "You are all out of gum! Bounce to make more!"
  62. end
  63. end
  64.  
  65. def do_inventory
  66. send "you look in your fannypack! you have #{@inventorybg} pieces of bubblegum!"
  67. if @inv.empty?
  68. send "You aren't carrying anything."
  69. else
  70. send "You are carrying:"
  71. @inv.each { |m| send "#{m.itemcolor} #{m.itemname}"}
  72. end
  73.  
  74. if @wear.empty?
  75. send "You aren't wearing anything."
  76. else
  77. send "\n You are balancing the following on your head:"
  78. @wear.each { |m| send "#{m.itemcolor} #{m.itemname}"}
  79. end
  80. send "You sense that your attack power is #{@inv.length}"
  81. send "You sense that your defense is #{@wear.length}"
  82. end
  83.  
  84. end
Add Comment
Please, Sign In to add comment