Inactive [FUN] GolfCraft v1.5.3 - Play golf with a bow and golf(snow)balls! [1.2.5-R1.0]

Discussion in 'Inactive/Unsupported Plugins' started by Musaddict, Apr 10, 2012.

  1. Offline

    Musaddict

    G[​IMG]lfCraft
    Version: v1.5.3​
    Authors: Musaddict
    Contributors: Feed_Dante

    GolfCraft lets you play golf! Create a golf course, save your holes, and have your users play a round! Every player's ball (arrow) will generate a sign where it lands, that way it's easy to find. They can't hit their ball again until they destroy it, and until their ball lands they can't move. Everything is scored based on the par that is set for each hole. Easy to make, easy to play!
    There are anti-griefing parameters in place to make sure no one's chat is spammed, and no one's world is spammed with signs!
    Thanks jeffro1001 for the request!

    Materials of recognition:
    • Green Wool: the Fairway (main material)
    • Lime Wool: the Green (putting material)
    • Sand: Sand Trap (stops balls from bouncing)
    • Glowstone: the Cup
    • Grass: the Rough (reduces ball's bounce velocity)
    • Fence: the Flag
    • Wood: Teeing Ground ( start of the course, gives your driver a boost)
    Features:
    • Clubs!
      • Up to 12 clubs to chose from
      • Each club has its own advantage
    • Snowballs!
      • Arrows are converted to snowballs when you shoot!
    • Create a golf course by adding holes
      • Creating holes set their par
      • The par is used for per-hole scoring
    • Per-hole golf-info chat channels
      • Any players in the same hole will know what happens with the other players
    • If the ball landed on a valid block, a sign with the player's name is placed, marking where the ball landed
      • This sign MUST be destroyed in order for another sign to generate
      • Once destroyed, the player cannot move more than one block away until their next ball lands in a valid location
    • Per hole scoring
      • Uses that hole's par to compare how many hits the player took.
      • Prints the score via number of hits, as well as golf lingo (Bogie, Eagle, etc)
    • SuperPerms
    • Plenty of anti-griefing parameters
      • I try my best to make sure players arent spammed with text or signs. I've spent most of my time coding making sure they cant.
    Source Code is currently Unavailable


    Recommended Builds:
    [​IMG] GolfCraft v1.5.3 [1.2.5-r1.0]

    Changelog:
    Version 1.5.3
    • Fixed permission nodes. All listed permission nodes now do exactly what they say.

    Version 1.5.2
    • Fixed some aesthetic discrepancies
    Version 1.5.1
    • Improved Physics!
      • Balls that bounce on the following materials have the following disadvantage:
        • Sand (barely bounces, if at all (like real sandtraps))
        • Grass (less bounce force)
        • Leaves (little to no bounce, as if it got caught in the tree)
        • Water (drastically reduces bounce)
        • Lava (melts the ball)
    • Added # of bounce config setting
      • Can only be set between 2 and 5
    Version 1.5.0
    • Added feature: "Golf balls" are now... Snowballs!
      • Change your texture for more realism!
      • All golf balls now bounce 3 times, and then generate a sign.
      • Putters now function better, due to the bouncing (and slight speed increase)
    • Broadcast messages now tell the club used when a player hits a ball.
    • Velocities now varry based on the club you use, and where you're standing
      • These are non-configurable (but the speed boost still is)
    • Thanks Feed_Dante for you glorious snowball contribution!
    Known Bugs:
    Thanks Feed_Dante for your contributions! Without them, we no have saved files, or snowballs!​
     
    hammale likes this.
  2. Offline

    kahlilnc

    Video? :D
     
  3. Offline

    md_5

    Approved.
     
  4. Offline

    Musaddict

    Uploaded one :)

    Thanks again man! The fourth you've approved of mine. Bound to be more headed your way soon :)
     
  5. havent tried this release yet, tried the earlyer one, and one of the problems (well lack of skill from my players) but they coulnt find their ball (sign) :p - so maby a admin command to delete a players sign, so he can start over would be a great idear.

    Great idear for a plugin.
     
  6. Offline

    Musaddict

    I'm actually about to upload a new version which allows OP's and players with the permission "golf.tp" to teleport to their sign. Also, players with "golf.tp.others" can teleport the specified player to their sign (if they have one).

    Code:
    /golf [tp] (player)

    Edit: Updated to 1.2.0
     
  7. Offline

    jeffro1001

    Awesome job Musaddict

    Thanks again!!
     
  8. Offline

    liralmogadi

    Hey, The only thing I'm abit worried about :
    I have a freebuild server with quite a big map, which is very organized around spawn. I wanted to know, Maybe, you could add a feature that u can enable and disable in the config, which does the following :
    In a region made with lets say /golf region create <name>, only there, people may play golf, and if their arrow gets out of the region, then it as if stops moving, and the sign spawns near the border? Because I don't want people spawning signs and everything everywhere near my spawn, and a controlled region would be an awesome idea to make great golf arenas. Thanks!
     
  9. Offline

    Freakdk

    It seems like most times, when the arrow hits another player, 2 signs will appear for the same player. This can also happen at random.

    The other thing is that players can use this for spamming purposes, etc. keep shooting arrows down a hole just to annoy people.

    Nice plugin though, I really hope you will do more work on it! :)

    Musaddict
    Also how about adding the possibility for admins to sell XP, not the bottles, but XP ;)

    (bug) My friend tafi fired his bow and he hit the fencepost (flag) and the sign replaced it;
    http://i.imgur.com/DcjJv.jpg

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 25, 2016
  10. Offline

    Musaddict

    Thanks :) Quick question. What material are you using for your teeing ground?

    Ah yes, thank you for reminding me about the fence post.

    How were you thinking of integrating selling XP in a golf plugin. Doesn't seem to fit :p

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 25, 2016
  11. Offline

    jeffro1001


    Green Wool ( same as the fairway )
     
  12. Offline

    Musaddict

    You dont have platforms or anything to signify the start of each hole? Like wood or anything?

    Reason I'm asking is cause I was gunna increase the velocity of the ball if they launched it from a wood platform, or some other material (as if you used a driver).
     
  13. Wow, this is the third plugin I have downloaded by you..........You make great plugins.
     
  14. Offline

    jeffro1001

    I was thinking about requesting that you add in a ' club selection' feature.
    Left clicking with the bow in hand would cycle you through all the different clubs, and depending on which club was selected that would determine the arrow velocity.

    Then again a feature like that would take away the 'skill factor' especially when close to the green.

    All in all I'm extremely happy with your work. I just finished my Front 9 and you've got an honorary club membership if you ever want to come play.

    Just got through playing the front 9 with the latest GolfCraft ( 1.2.0) and there are a few things I think need tweaking:

    The sand trap 'debuff' is a bit too extreme. I had one player take at least 20 shots to get out of a trap. He would power his bow all the way and the arrow wouldnt even fly 1 block.

    Suggestion:
    A config file where the server admin can adjust the ammount of debuff you get from sand.
    I really do like that feature, and I'm glad you added it, but I think it needs to be tweaked.
    ------------------------------------
    The 'will not allow you to move' feature will not dissappear, even if you leave golf mode.

    I found the only way to get mobility again was to either finish out a hole, or spawn a glowstone block on the ground to shoot. ( to make GolfCraft think you finished the hole.)

    Also, while the movement inhibitor is a good 'anti-cheat' there isnt any recourse for a ball shot 'Out of bounds'
    The player is forced to play their shot from OB.

    Suggestion:
    A command that allows you to 'take a drop'

    /golf takeadrop

    This command would be used by the player that shot OB or landed in an unplayable spot.
    He would stand on the spot ( back in bounds ) where he would 'drop his ball' by typing /golf takeadrop
    The command would remove the sign sitting OB, and spawn a new one where he is standing. He could then destroy that sign to continue golfing.

    Also, if a player needs to leave the game prematurely ( we all know RL things pop up ) there needs to be a way for them to completly exit out of golf mode and remove the 'lock you in place' feature.
    --------------------------------------------
    Have you taken into account Lava? Whoever heard of a lava hazard? Well maybe in Hawaii hehe

    Well my back 9 will have a few lava hazards to deal with, and I'm not sure if you have taken that into account.


    That's all I could find so far, and Ill let you know if I come across anything else.

    I love this plugin!!



    Oh I forgot to ask,
    What is a (WIP) Scoring system.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 25, 2016
  15. Offline

    Musaddict


    Lol looks like I got my hands full. "(WIP) scoring system" is "Work in Progress scoring system", and it's almost finished. I'm just about finished with the next major update, which will allow you to "create" holes. Created holes are wherever you're standing at the time of creation (should make them on the teeing ground)

    Code:
    /golf create [hole name] [par]
    Creating holes will allow you to set the par for that hole. These created holes will then allow you to play them using
    Code:
    /golf play [hole name]
    Doing so will teleport you to that hole's teeing ground, and will reset your score for that hole. Based on how many times it takes you to get in the hole, it will tell you your total for that round + double eagle/eagle/birdie/par/bogie/db/tb.


    As for lava hazards, that will be simple :) as for taking a drop, i'll see what I can do. As for selecting clubs, that sounds difficult :p but not impossible. I'll get to work on something after I release 1.3.0.

    I'll also fix the sand traps, tho I dont think i'll add a config in this next update.


    Edit: Oh, also, adding the user-defined holes also means that there will be hole-specific golf chat activity (players on hole 7 wont hear golf data from players on hole 3)

    Thanks :)
     
  16. Offline

    jeffro1001

    Soounds awesome!
    I can't wait.
     
  17. Offline

    Musaddict

    Updated to 1.3.0, and might I say? It's glorious. :)
     
    Perfk likes this.
  18. Offline

    gawelium

    Version 1.3.0 doesn't work. Couldn't load golfcraft.jar
     
  19. Offline

    Musaddict

    From the OP:

    Note: BlockCraft was compiled using Java 1.7. If you are having issues enabling GolfCraft, please update your java version to 1.7, otherwise it will not work!

    If that does not work, please paste the error message.
     
  20. Offline

    gawelium

    Why java 1.7 ?? :eek:

    Error message :

    Code:
    [SEVERE] Could not load 'plugins\GolfCraft.jar' in folder 'plugins'
    org.bukkit.plugin.InvalidPluginException: java.lang.UnsupportedClassVersionError: musaddict/golfcraft/Golfcraft : Unsupported major.minor version 51.0
        at org.bukkit.plugin.java.JavaPluginLoader.loadPlugin(JavaPluginLoader.java:150)
        at org.bukkit.plugin.SimplePluginManager.loadPlugin(SimplePluginManager.java:305)
        at org.bukkit.plugin.SimplePluginManager.loadPlugins(SimplePluginManager.java:230)
        at org.bukkit.craftbukkit.CraftServer.loadPlugins(CraftServer.java:207)
        at org.bukkit.craftbukkit.CraftServer.<init>(CraftServer.java:183)
        at net.minecraft.server.ServerConfigurationManager.<init>(ServerConfigurationManager.java:53)
        at net.minecraft.server.MinecraftServer.init(MinecraftServer.java:156)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:422)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:492)
    Caused by: java.lang.UnsupportedClassVersionError: musaddict/golfcraft/Golfcraft : Unsupported major.minor version 51.0
        at java.lang.ClassLoader.defineClass1(Native Method)
        at java.lang.ClassLoader.defineClassCond(Unknown Source)
        at java.lang.ClassLoader.defineClass(Unknown Source)
        at java.security.SecureClassLoader.defineClass(Unknown Source)
        at java.net.URLClassLoader.defineClass(Unknown Source)
        at java.net.URLClassLoader.access$000(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(Unknown Source)
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:41)
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:29)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Unknown Source)
        at org.bukkit.plugin.java.JavaPluginLoader.loadPlugin(JavaPluginLoader.java:139)
        ... 8 more
    
     
  21. Offline

    jeffro1001

    No issues loading it here.

    I haven't had time to play with it yet though. I've got to actually get some RL work done. :)

    Quick question..

    Are there any limitations for hole names? Can they have spaces in the name?

    ex:

    /golf create Pyramid Sands Hole1 4

    or will that just not work?

    Would it be possible to incorporate using signs to begin a hole?

    That way players can just click the sign at the tee box and it will be like they typed in the command

    /golf play Pyramid Sands Hole1


    I'm eventually planning on creating more than one course.

    Also, I've been playing around with the idea of creating a completely seperate world 'GolfWorld'

    Will GolfCraft support multi-world?
     
  22. Offline

    Gabipabie

  23. Offline

    jeffro1001



    Musaddict,

    Can you add a 1 stroke penalty for water hazards?

    The rules of Golf impose a 1 stroke penalty for landing in a water hazard.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 25, 2016
  24. Offline

    Musaddict

    As in they get 2 points when they land in the water? (1 for hitting it, 1 for landing in the water)

    Also, does taking a drop apply for water hazards? Or do they stay where they were when they hit the ball?

    Ya, you need to update java to 1.7.
    Choose your OS from this list, and it should work for you. We use methods only available in Java 1.7 (jre-7).
    http://www.oracle.com/technetwork/java/javase/downloads/java-se-jre-7-download-432155.html

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 25, 2016
    jeffro1001 likes this.
  25. Offline

    jeffro1001

    For water hazards, the stroke you took ( that landed you in the water ) counts, and you take another stroke penalty to drop the ball.

    The ball can be dropped anywhere between where the ball crossed the waters edge and where you took the shot.

    The best way to handle it I think would just code in +1 shots for landing in the hazard, and have them shoot from where they last shot.
     
  26. Offline

    norsac321

    Suggestion:Automaticly teleport to were ever the Ball landed. Because I have a survival server that runs this plugin but no one likes having to try and find there Ball, Let alone walking to it. So please make it so that it teleports people to were there ball landed.​
     
  27. Offline

    Musaddict

    Instead I was planning on having monsters despawn when they walk on green or lime wool (configurable). The point of this plugin is to walk and experience golf courses. If you'd like them to teleport, you can just give them the "golf.tp" permission, and they will be able to use "/golf tp". Simple enough :)

    Ok. I'm not at home at the moment, so I wont be able to release 1.3.1 until later tonight. I plan to add a configuration, fix the hazard scoring, and **maybe** add a /golf drop command (take a drop).

    I had an epiphany this morning on how to manage different clubs, but it will take me a while to prove my theory and work it out. I will let everyone know if my planned theory works, and hopefully release something on Saturday (I'm pretty swamped for today and tomorrow).


    Edit: I was thinking of making water hazards +1 penalty, and lava +2 penalty. Do you agree with this? Or would you rather keep lava +1 penalty?


    To answer your questions, spaces are not supported in hole names (but underscores are), I plan to incorporate signs to begin each hole as an alternative, and GolfCraft is multi-world compatible! You can have "Hole1" on world, and "Hole1" on GolfWorld, ergo you can have the same named hole multiple times, once on each world. In order to start a hole on a different world, you must first be in that world, otherwise "/golf start" will give you an error, or port you to a hole with that name on your world if it exists.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 25, 2016
  28. Offline

    jeffro1001

    I've seen the console get spammed with this often, but it doesnt seem to affect anything:

    2012-04-12 20:36:59 [SEVERE] Could not pass event ProjectileLaunchEvent to Golfcraft
    org.bukkit.event.EventException
    at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:303)
    at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62)
    at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:459)
    at org.bukkit.craftbukkit.event.CraftEventFactory.callProjectileLaunchEvent(CraftEventFactory.java:504)
    at net.minecraft.server.World.addEntity(World.java:897)
    at net.minecraft.server.World.addEntity(World.java:864)
    at net.minecraft.server.PathfinderGoalArrowAttack.f(PathfinderGoalArrowAttack.java:80)
    at net.minecraft.server.PathfinderGoalArrowAttack.e(PathfinderGoalArrowAttack.java:69)
    at net.minecraft.server.PathfinderGoalSelector.a(SourceFile:55)
    at net.minecraft.server.EntityLiving.z_(EntityLiving.java:1229)
    at net.minecraft.server.EntityLiving.e(EntityLiving.java:1109)
    at net.minecraft.server.EntityMonster.e(EntityMonster.java:21)
    at net.minecraft.server.EntitySkeleton.e(EntitySkeleton.java:67)
    at net.minecraft.server.EntityLiving.F_(EntityLiving.java:447)
    at net.minecraft.server.EntityMonster.F_(EntityMonster.java:25)
    at net.minecraft.server.World.entityJoinedWorld(World.java:1264)
    at net.minecraft.server.WorldServer.entityJoinedWorld(WorldServer.java:106)
    at net.minecraft.server.World.playerJoinedWorld(World.java:1246)
    at net.minecraft.server.World.tickEntities(World.java:1153)
    at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:542)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:449)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:492)
    Caused by: java.lang.NullPointerException
    at musaddict.golfcraft.GcEntityListener.onProjectileLaunch_Func(GcEntityListener.java:73)
    at musaddict.golfcraft.GcEntityListener.onProjectileLaunch(GcEntityListener.java:37)
    at sun.reflect.GeneratedMethodAccessor76.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:301)
    ... 21 more

    Hazard penalty should stay at +1 for both lava and water.

    Looking forward to seeing the updates.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 25, 2016
  29. Offline

    Musaddict

    Ah, looks like I forgot to account for the fact that skeletons aren't players :p will be fixed in the next update.
     
  30. Offline

    Niff

    So, awesome plugin, I love golf and would love to try this out, but I have a question: is there any way you could set up an option to require someone to be within 50 or so tiles of the hole they want to start (or some other way to allow people to start golfing without needing a teleport)? I run a PVP server that this would still be fun to have, but I can't have people running around teleporting to various holes to avoid being attacked.

    -Niff
     

Share This Page