Inactive [FUN,ADMN] Slap v0.8 - Slap your players. Show them who's boss. [2126]

Discussion in 'Inactive/Unsupported Plugins' started by rakiru, May 10, 2011.

  1. Offline

    rakiru

    Slap
    Version: v0.8.0

    Some of you may recognise this command if you've ever run a CS:S server, or another Source game, using ManiAdmin. It allows you to "slap" players into the air.

    Features:
    • "Slap" players into the air (with varying degrees of force) with a command
    • Partial name matching
    Download Slap
    Source Code
    Old versions

    How to use:
    • Syntax: /slap <username> [force:0-10, default 2]
    • Example: /slap rakiru
    • Example: /slap rak 4.5
    • Syntax: /megaslap [force:0-10, default 2] [broadcase:true|false, default true]
    • Example: /megaslap
    • Example: /megaslap 10
    • Example: /megaslap 7.9 true
    Permissions:
    If you do not have permissions installed, the plugin will default to OP only. If you do have it installed, only players with the right permissions node(s) will be able to use the command(s)/feature(s), and will ignore OP privileges.
    • /slap - slap.slap
    • /megaslap - slap.megaslap
    Custom messages:
    You can customise the messages Slap uses in the config.yml file. Slap will replace the string "{SLAPPER}" with the name of the player using the command, and "{PLAYER}" with the name of the player being slapped. More details on this can be found on the wiki.

    To do:
    • Fix only being able to slap people from within game Fixed in 0.5.3
    • Finer precision permissions for force
    • Varying slap messages Added in 0.5
    • Configurable slapping messages - @Phase Added in 0.6
    • Configure option/switch to give the person temporary godmode until they land again - @Phase
    • If NoCheat is installed and the player does not have permission to fly, teleport them high up
    • Add config option for above
    • Megaslap command - Slap all players within an optional radius Added in 0.7
    • Taking suggestions...
    Changelog:
    Version 0.8
    • Updated to newest bukkit
    • Refactored code
    Version 0.7
    • Megaslap command
    Version 0.6
    • Configurable chat messages
    Version 0.5
    • Different messages depending on force
    • Finished changing name to "Slap" from "Slap!"
    Version 0.4
    • Added optional permissions support
    Version 0.3
    • Initial public release
     
    KHCraft likes this.
  2. Offline

    msw1

    I like this.
     
    ShootToMaim likes this.
  3. Offline

    Windwaker

    lolwut? Haha

    Now go make me a sammich
     
  4. Offline

    rakiru

    Updated to v0.5
     
  5. Offline

    Phase

    I've actually thought about a plugin that does this since the hMod days. I'm glad someone else thought of it too :)

    Nice work, I like it.

    Suggestions:
    • Configurable slapping messages
    • Configure option/switch to give the person temporary godmode until they land again.. so, sort of like a friendly slap.
    I especially hope you can come up with a solution to the second one.

    Thanks!
     
  6. Offline

    rakiru

    When I started running my server, I missed /slap from CS:S, but I just didn't get around to it until now. Someone on #bukkitdev liked the idea too and said they'd do it themselves if I didn't. lol

    I've been considering the best way to add custom messages to it. Any ideas?
    The second one is a possibility I guess. I'll try it out later. I did add a slap force so you can slap them without harming them, since even without fall damage, if they landed in lava, even the smallest slap could kill them. ;)

    Thanks for the suggestions! :D
     
  7. Offline

    Phase

    Anytime!

    What about a YAML config file with something along the lines of:
    Code:
    messages:
      2:
        - 'slapped {PLAYER}'
      5:
        - 'smacked {PLAYER} across the face. Ouch!'
      9:
        - 'uppercutted {PLAYER} with immense force'
    

    With this config it would work like this:
    Code:
    Force 0 through 2 would display: "slapped {PLAYER}"
    Force 3 through 5 would display: "smacked {PLAYER} across the face. Ouch!"
    Force 6 through 10 would display: "uppercutted {PLAYER} with immense force"
    
    So basically, you are able to assign a force value 0-10 like above, and it would account for missing values. If you wanted 1, 2, and 3 all to show the same message.. you need only to start at third value.

    If only one value was assigned, no matter the number, it would show that message for all force values. Also, if no messages were defined at all, it could default to a hardcoded set of messages.. perhaps the ones you use now.

    I hope this makes sense :)
     
  8. Offline

    rakiru

    Sounds good. I'll try to get this added later tonight. :)
     
  9. Offline

    Phase

    Sweet :)
     
  10. Offline

    Ryoma

    its been in CommandBook plugin for quite a while now
    http://forums.bukkit.org/threads/ge...-new-midi-intro-intro-music-on-join-740.6525/
     
  11. Offline

    rakiru

    I wondered how it could have taken this long for it to be made. I don't use CommandBook, so didn't know.
     
  12. Offline

    Phase

    What changed from 0.5.1 to 0.5.2?
     
  13. Offline

    rakiru

    Bug fixes. Nothing major.
     
  14. Offline

    Max Maton

    Cool plugin, i definitely need to show my players who's boss!
     
  15. Offline

    Phase

    Alright cool :)

    Can you add in the ability to not show the messages at all? On our server someone likes using it to slap themselves really high and take screenshots.. as you can imagine it's quite spammy in game chat.
     
  16. Offline

    rakiru

    Sure, I'll add it in 0.6 along with custom messages.
     
  17. Offline

    Phase

    Sounds good.

    Whenever you issue slap in the server console:
    Code:
    16:54:11 [WARNING] Unexpected exception while parsing console command
    org.bukkit.command.CommandException: Unhandled exception executing command 'slap' in plugin Slap v0.5.2
            at org.bukkit.command.PluginCommand.execute(PluginCommand.java:37)
            at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:85)
            at org.bukkit.craftbukkit.CraftServer.dispatchCommand(CraftServer.java:270)
            at net.minecraft.server.MinecraftServer.b(MinecraftServer.java:396)
            at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:381)
            at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:287)
            at net.minecraft.server.ThreadServerApplication.run(SourceFile:394)
    Caused by: java.lang.ClassCastException: org.bukkit.craftbukkit.command.ColouredConsoleSender cannot be cast to org.bukkit.entity.Player
            at com.fuckingwin.bukkit.rakiru.slap.SlapCommand.onCommand(SlapCommand.java:30)
            at org.bukkit.command.PluginCommand.execute(PluginCommand.java:35)
            ... 6 more
    
     
  18. Offline

    rakiru

    Ah, I forgot to test from console. I'll look into it, thanks.
     
  19. Offline

    KHCraft

    Am I the only one who can't access the download link? I want to use it but I can't get it >_<
     
  20. Offline

    rakiru

  21. Offline

    Phase

    No problem rakiru, I've spent the last few days focused on another project of mine. :)
     
  22. Offline

    KHCraft

    :D THANK YOU <33333333

    [diamond][diamond][diamond]
    You deserve them. But don't spend em all in one place now.
     
  23. As a server admin I find it much more effective and fun to slap someone with a force of 100 (it says you b*tch slapped them) than Warning them.

    Future Idea would be to make a command such as /slap list to see how many times someone has been slapped.
    Again that's just an idea.
    AMAZING PLUG IN[cake]
    Time to go B*tch slap my best friend........In minecraft.
     
  24. Offline

    BobbyJ

    What are the permissions? i need those pleasee :)
     
  25. Offline

    Phase

    The permission for /slap is: slap.slap
     
  26. Offline

    Senzuri

    Nice plugin, doesn't work with NoCheat though.
     
  27. Offline

    rakiru

    As it says in the main post under the Permissions heading.
    NoCheat stops players from being able to move in any way other than the normal minecraft movements or teleporting. This plugins makes them move in a way that isn't default minecraft movements, so that's why it's getting caught. There's nothing I can do about this, sorry, it does what NoCheat stops you from doing.
     
  28. Offline

    Diabloste

    Hi! Fantastic plugin. Was supposed to make something looking a lot like it, seems like you were faster hah!

    Anyways. What about a /whip command? For example /whip <name> <amount of times>
    That would slap a certain player for X amount of times! Could be fun :p
     
  29. Offline

    BobbyJ

    Thanks i did find it but since it was only one permissions i had trouble finding it. But great plugin. I Slap My friend everytime they piss me off hehe :p
     
  30. Offline

    rakiru

    Haha, so much more effective than a kick, isn't it?
    I've added more permissions in for 0.6.
     

Share This Page