[INACTIVE][FUN] Jackpot v0.2.3 - Dice/Coins/Cards! [670]

Discussion in 'Inactive/Unsupported Plugins' started by Hunt800, Apr 10, 2011.

  1. Offline

    Hunt800

    Jackpot - Gambling Commands:
    Version: v0.2.2

    This is my first shot at a plugin. While it's incredibly simple at the moment, I aim to have it include many different commands to aid with gambling on SMP server. From simple coin tosses, to complex Poker games, hopefully this plugin will someday handle it all!

    Features:
    • /roll command for rolling dice (locally and globally)
    • /cointoss command for flipping coins
    • /card command for playing with decks
    • Permissions support!
    • A simple config file for setting some defaults
    Download Jar

    Source Code

    Commands (BASIC)
    • /roll <# of dice> <sides on dice> <OPTIONAL> - If left blank, # of dice will default to 1 and sides of dice will default to whatever it is in the config. <OPTIONAL> can be left blank to broadcast locally, or changed to g to broadcast results globally.
    • /cointoss <# of coins> <OPTIONAL> - # of coins will ALWAYS default to 1 if left blank, <OPTIONAL> is the same as above.
    Commands (CARDS)

    The current /card system can be confusing, which is why it deserves its own section! Before I begin with commands, let me explain the basics of the system:
    Each player (upon logging in) is given a unique 'set' of cards. This set contains a lot of information - such as all the cards not yet dealt, the cards drawn (not dealt to a specific player), and a list of players with the cards that have been dealt to them. Because of this setup, in the commands, players sometimes need to refer to the player's 'set' that they are trying to access. For example, if I am playing with Nooby1 and Nooby2, and they have both dealt me cards, I would use '/card mine Nooby1' to see the cards that Nooby1 dealt and '/card mine Nooby2' to see the cards that belong to Nooby2'
    • /card shuffle - This will 'reset' your entire personal deck, making it seem like you just logged in
    • /card draw - This will take a card from YOUR deck (broadcasting the card locally) and place it into the center (see /card see <NAME>)
    • /card deal <NAME> - This will deal a card from YOUR deck to a player. No one but the player you dealt to will see the card
    • /card see <NAME> - This will show you all the cards currently in the center of <NAME>'s "set"
    • /card mine <NAME> - This will show you all the cards that <NAME> has dealt to you since <NAME>'s last shuffle
    • /card show <NAME> - This will LOCALLY BROADCAST all the cards that <NAME> has dealt to you. This command will let nearby players know what cards you are holding, so until the end of a hand, only use /card mine <NAME>
    • /card left <NAME> - This is more of an admin command and was really only used for testing (by me). Basically, it shows (very dirtily) all the cards that have yet to be dealt in <NAME>'s deck. You probably shouldn't give this one out, since it makes cheating possible
    Permissions Nodes

    • 'jackpot.roll.local' - Allows user to roll dice with /roll <# of dice> <sides on dice>
    • 'jackpot.roll.global' - Allows user to add 'g' to the end of a roll command to broadcast the result globally. Player MUST have jackpot.roll.local for this to work
    • 'jackpot.flip.local' - Allows user to use /cointoss <# of coins>
    • 'jackpot.flip.global' - If the player has jackpot.flip.local then they can add 'g' to a /cointoss command to broadcast globally
    • 'jackpot.card.shuffle' - /card shuffle
    • 'jackpot.card.draw' - /card draw
    • 'jackpot.card.deal' - /card deal <NAME>
    • 'jackpot.card.see' - /card see <NAME>
    • 'jackpot.card.mine' - /card mine <NAME>
    • 'jackpot.card.show' - /card show <NAME>
    • 'jackpot.card.left' - /card left <NAME>
    Config.properties

    At the moment, the config is simple:
    • broadcast-distance - distance a result will be broadcast if the user does not make it global.
    • default-dice-size - if the user simply types /roll this is the number of sides that the dice will use.
    • play-with-cards - if false, the plugin will run without any /card features
    To Do:

    • Figure out a simpler /card system? Help me with this one!
    • Sign based gambling support? (ie, players can create a sign that lets other players gamble with iConomy money, even when the owner is offline)
    • More? You tell me what you want to see next!
    Changelog:

    Version 0.2.3
    • Added a play-with-cards config field for disabling all card features
    • Fixed code that generates config file so it will add any missing fields
    • Added ability to use "/roll #" to roll without specifying sides. It will roll # dice with the default number of sides
    • Added ability to use "/cointoss g" instead of needing to include a number of coins before "g"

    Version 0.2.2
    • Added card support (complicated at the moment)

    Version 0.1.7
    • Released the plugin
    • Support for dice and coins
    • Permissions nodes
    • Ability to add "g" to the end of commands to globally broadcast results
     
    NEO and renxwar like this.
  2. Offline

    Plague

    considered inactive
     
  3. Offline

    ezzzdiy

  4. Offline

    Hunt800

    Thanks. If you need anything let me know. It's an incredibly simple plugin at the moment, but I have a bad habit of not commenting, and if I recall correctly, the structure of this one was a bit messy. So, if there's any confusion concerning what does what or why I did something, just shoot me a PM.
     

Share This Page