[RPG/MECH] Turnstile v1.9.1 - Charge players money/items to enter an area [953]

Discussion in 'Inactive/Unsupported Plugins' started by Codisimus, Mar 15, 2011.

  1. Offline

    Codisimus

    This page will no longer be updated. Please follow this project at the Bukkit Dev Page

    Turnstile - Charge players money/items to enter an area:
    Version: 1.9.1 (7/16/2011)
    Supports iConomy, BOSEconomy, Essentials, Permissions
    Download Page

    This plugin is used to create a Turnstile to prevent players from entering certain locations without paying money/items.

    The Turnstile is made up of a fence block, this block will disappear when a linked button is clicked. The block will reappear when walked through or after a certain amount of time. Money is deducted from the user when they press the button (or walk through the Turnstile if 'NoFraud' is set to true in the config). All money deducted is given to the owner/bank of the Turnstile.

    Turnstiles can also charge items by linking a chest instead of a button. Put the required item in and punch the chest to open the Turnstile.

    Format of Save file:
    Show Spoiler

    Code:
    DreknorIn;1;4;13;2;scudmaster;Codys_World;-174;55;-102;
    -175:55:-101;-174:55:-99;
    
    [Name];[Price];[Earned];[ItemID.Damage Value];[Amount of item];[Owner];[WorldName][x];[y];[z](of location of Turnstile);
    [x];[y];[z](of location of linked button/chest);[x];[y];[z] (of location of linked button/chest);

    Features:
    • Configurable properties.
    • Custom messages
    • No Fraud mode (Turnstile doesn't charge until walked through)
    • Restrict use of a specific Turnstile to a certain group
    • Make a Turnstile Free or Locked during a certain time of day
    • Autoclose timer
    • Create private Turnstiles only you can use
    • Only owners and admins can destroy Turnstile blocks, buttons, and chests
    • Edit turnstiles easily in game or in the save file
    • Only the owner/bank owner can edit a turnstile
    • Turnstiles can charge specific items instead of money
    • Durability support
    • Turnstiles can also be free to use
    • Charge users money to create turnstiles
    • Set different Turnstiles to unique prices and owners/banks
    • List and locate Turnstiles
    • MultiWorld support
    • Uses iConomy, BOSEconomy or Essentials to charge users money
    • Permissions to limit players from using turnstiles, for all commands (except help), and for admins
    • Included in CraftBukkitUpToDate for easy updating (make sure you come check the changelog if somthing is not working right)
    Commands:
    Commands can be written as /turnstile or /ts
    Show Spoiler

    • /ts make [Name] - Make target fence block into a Turnstile
    • /ts link [Name] - Link target block with Turnstile
    • /ts rename [Name] [NewName] - Renames the Turnstile
    • /ts unlink [Name] - Unlink target block with Turnstile
    • /ts delete [Name] - Delete Turnstile and unlink blocks
    • /ts price [Name] [Price] - Set cost of Turnstile
    • /ts price [Name] [ItemID(.Damage)] [Amount] - Set cost to item
    • /ts access [Name] public - Allow anyone to open the Turnstile
    • /ts access [Name] private - Allow only the owner to open
    • /ts access [Name] [Group] - Allow only specific Group to open
    • /ts free [Name] [TimeStart-TimeEnd] - Free during timespan
    • /ts locked [Name] [TimeStart-TimeEnd] - Locked during timespan
    • /ts earned [Name] - Display money the Turnstile earned
    • /ts collect - Retrieve items from the target Turnstile chest
    • /ts owner [Name] [Player] - Send money for Turnstile to Player
    • /ts bank [Name] [Player] - Send money for Turnstile to Bank
    • /ts list - List all Turnstiles
    • /ts info - Gives info of Turnstile
    • /ts help - Displays Turnstile help page

    Permission Nodes:
    Show Spoiler

    • turnstile.open - Needed to be able to activate Turnstiles
    • turnstile.openfree - Player/Group is not charged to open Turnstiles
    • turnstile.make - Needed to make/link/unlink/delete Turnstiles
    • turnstile.makefree - Player/Group is not charged to make Turnstiles
    • turnstile.set.free - Allows Player/Group to use /ts free
    • turnstile.set.locked - Allows Player/Group to use /ts locked
    • turnstile.set.price - Allows Player/Group to use /ts price
    • turnstile.set.owner - Allows Player/Group to use /ts owner
    • turnstile.set.access - Allows Player/Group to use /ts access
    • turnstile.set.bank - Allows Player/Group to use /ts bank
    • turnstile.earned - Allows Player/Group to use /ts earned
    • turnstile.admin.list - Allows Player/Group to use /ts list
    • turnstile.admin.info - Allows Player/Group to use /ts info
    • turnstile.admin.ignoreowner - Player/Group can edit any Turnstile regardless of being the owner

    Tutorial:
    NOTE: New Tutorial video, Please watch before asking questions.




    ToDo:
    • Send items to owner
    • Add option of using a door instead of a fence block
    • Add pressure plate support
    Changelog:
    Old Versions + ChangeLog can be found at Download Page
    Show Spoiler

    Version 1.9.1 (7/16/2011)
    • Added rename command
    • Now allows multiple Turnstiles per block
    • Fixed Access
    • Added color support for all customizable messages
    Version 1.9 (6/26/2011)
    • Improved OP options
    • Updated Economy support
    • Fixed collect command
    • Added option of door instead of block
    • Added pressure plate support
    Version 1.8 (6/12/2011)
    • Cleaned up code/fixed errors
    • Added /ts collect command to retrieve earned items
    Version 1.7.6 (6/4/2011)
    • Cleaned up errors and added error messages
    Version 1.7.5 (6/3/2011)
    • Various fixes and code cleanup
    Version 1.7.4 (6/3/2011)
    • Added Essentials econ support
    Version 1.7.3 (5/20/2011)
    • Fixed durability support
    Version 1.7.2 (5/20/2011)
    • Added decimal support
    Version 1.7.1 (5/16/2011)
    • Readded the useOpenFreeNode and useMakeFreeNode options in config
    Version 1.7 (5/15/2011)
    • Changed permission nodes
    • Allow right clicking a button to open
    • Made Turnstiles unbreakable
    • Added command to allow group specific Turnstiles
    Version 1.6.1 (5/4/2011)
    • Updated to iConomy 5
    • Few various fixes
    Version 1.6 (4/29/2011)
    • Added durability support
    • Added custom messages
    • Fixed reload issues
    • Added No Fraud mode (Turnstile charges when walked through)
    • Added option to restrict use of a specific Turnstile to a certain group
    • Added option of making a Turnstile Free or Locked during a certain time of day
    • Added autoclose timer
    Version 1.5 (4/15/2011)
    • Improved multiworld support
    • Other various fixes
    Version 1.4.3 (4/4/2011)
    • Fixed isOp() conflicting with Permissions
    Version 1.4.2 (3/31/2011)
    • Few minor fixes
    • Works with build #612
    Version 1.4.1 (3/30/2011)
    • Can now use with left or right hand
    Version 1.4 (3/30/2011)
    • Fixed turnstile creation
    Version 1.3.3 (3/30/2011)
    • Updated to build #602
    • Changed the way you create turnstiles. Now you must target the fence block that will become a Turnstile
    Version 1.3.2 (3/28/2011)
    • Added private Turnstiles, Set price to -808 to make it so only the owner can enter
    Version 1.3.1 (3/28/2011)
    • Fixed error of crashing if owners name is < 5 letters long
    Version 1.3 (3/26/2011)
    • Added protection for Turnstile blocks, buttons, and chests
    Version 1.2.1 (3/24/2011)
    • Various fixes
    Version 1.2 (3/23/2011)
    • Fixed multiworld support
    Version 1.1 (3/23/2011)
    • Fixed paying with items not opening Turnstile
    Version 1.0 (3/23/2011)
    • Added an autoclose timer (set to -1 as default in config file meaning it will stay open until walked through)
    • Added '/ts earned [Name]' command (no permission node)
    • Fixed config
    • Added option of setting price to all (saved as -411 in save file) which will clear a players balance as the cost
    • Fixed error of turnstile opening without enough money
    • Fixed permissions reload
    • Fixed/added lots of other things I can't even remember
    Version 0.9 (3/22/2011)
    • Fixed error of no confirmation messages for iConomy
    • Added a check to make sure the balance has enough money
    • Implemented option of paying with a specific item
    • Added config file with the following options
      • CostToMakeTurnstile=0
      • useIgnorePriceNode=False
      • useIgnoreCostNode=False
    Version 0.8.3 (3/19/2011)
    • Fixed unknown command spamming chat
    • Fixed no Economy message spamming
    • Changed /ts locate to /ts info (turnstile.admin.info)
    Version 0.8.2 (3/19/2011)
    • Added multiworld support (you must rename save files to Turnstile[WorldName].save or turnstiles will not be loaded)
    Version 0.8.1 (3/18/2011)
    • Fixed /ts bank not working
    • Added /ts bank to help page
    • /ts bank now only works with BOSEconomy linked
    Version 0.8 (3/18/2011)
    • Added support for BOSEconomy banks
    • New node turnstile.admin.bank
    • New command /ts bank [Name] [Bank]
    Version 0.7.1 (3/17/2011)
    • Mispelled commands display help screen
    • If owner is set to "server" then money is not added or deducted from the owner
    • Button now only works when turnstile is closed
    Version 0.7 (3/17/2011)
    • Turnstile now closes after being walked through
    • Fixed error of "Turnstile successfully loaded with Permissions!" being displayed multiple times
    Version 0.6.1 (3/16/2011)
    • Fixed error that Permissions was required
    Version 0.6 (3/16/2011)
    • Added support for Permissions
    Version 0.5 (3/16/2011)
    Version 0.4 (3/15/2011)
    • Limited commands to the owner of the turnstile
    • Other various fixes
    Version 0.3 (3/15/2011)
    • Initial Release
     
  2. Offline

    Codisimus

    config.properties inside the turnstile folder
     
  3. Offline

    Chaoz

    Ok i have no config file inside the folder. I don't know why but it isn't there.
     
  4. Offline

    Codisimus

    is your server by any chance on a linux machine?
     
  5. Offline

    Chaoz

    Its a Debian Lenny 5.0 OS don't know if its similar to Linux.
     
  6. Offline

    Codisimus

    redownload version 1.2.1, it should work now
     
  7. Offline

    Chaoz

    GREAT ! :D it's working now !

    thanks for your fast help :D

    Hey I just want to mention one thing. Wouldn't it be better if the fences wouldn't be destroyable?

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

    Codisimus

    well it would but im not gonna bother adding that bc even if they cant destroy the fence they could just destroy blocks around it right? i guess its not that hard to add... if you guys think i should add it then i will
     
  9. Offline

    kenjamen


    Actually I'd recommend looking into epiczones or factions to control/secures areas. I include lwc as additional. I think it's a better idea to integrate zoning with Epiczones and leave it out of each and every plugin. what do u guys think? I can see one issue with this though, if u can't trust other faction members...(they could damage it).

    ** Going to test this with lwc and see if others can still use it
     
  10. Offline

    dak393

    Latest update of iConomy, your plugin is no longer deducting money >.> says that it did but there is no change in my balance. Will double check I didn't change admins paying.
     
  11. Offline

    firefly_goat

    No that's not what I mean, I mean when you press the button and go trough the turnstile you will charged for example 20coins and you will receive a minecart so you can ride from your minecart station, so you don't have to have all your minecarts in a chest!
     
  12. Offline

    dak393

    Probably not the right plugin for that you could try craftbook's minecart dispensers or use minecartmania's version
     
  13. Offline

    Codisimus

    if you are the owner it will deduct money from ya and then just give it right back to you (so no change in balance)
    PhatLoots isnt just a bunch of minecarts in a chest, it spawns a new one when a player opens the chest.
     
  14. Offline

    Hant

    if i use /ts price [name] 1
    i can use the button:

    2011-03-25 23:32:31 [SEVERE] Could not pass event BLOCK_DAMAGED to Turnstile
    java.lang.StringIndexOutOfBoundsException: String index out of range: 5
    at java.lang.String.substring(String.java:1934)
    at turnstile.TurnstileMain.charge(TurnstileMain.java:166)
    at turnstile.Turnstile.checkBalance(Turnstile.java:105)
    at turnstile.TurnstileBlockListener.onBlockDamage(TurnstileBlockListener.java:39)
    at org.bukkit.plugin.java.JavaPluginLoader$22.execute(JavaPluginLoader.java:269)
    at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:59)
    at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:255)
    at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:358)
    at net.minecraft.server.Packet14BlockDig.a(SourceFile:42)
    at net.minecraft.server.NetworkManager.a(SourceFile:230)
    at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:76)
    at net.minecraft.server.NetworkListenThread.a(SourceFile:100)
    at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:357)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:272)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:366)
     
  15. Offline

    Codisimus

    can i see your save file?
     
  16. Offline

    joedan

    I use an obsidian or bedrock entrance that's almost impossible to pass however I am seeing users just break the turnstile fence and enter without paying. Is there another plugin I can use to protect the turnstile without breaking this one?
     
  17. Offline

    Codisimus

    i can add it... not too much coding
     
  18. Offline

    dak393

    any area protection like worldguard or Preciousstones or one of many other just search the forums
     
  19. Offline

    Codisimus

    Version 1.3 has new feature "Turnstile blocks, buttons, and chests protected from being destroyed"

    no i understand, why get a entirely new plugin to protect one block.

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

    joedan

    Thank you so much, that was amazingly fast!

    Works like a charm

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

    dak393

    Ya was just saying in the mean time, and hey block protection can be very useful on servers to have anyways
     
  22. Offline

    Codisimus

    I want to develop an easier to use block protection but can't think of the easiest way for people to do it
     
  23. Offline

    zwarmapapa

    Is there an option to turn the block protection off?
     
  24. Offline

    Codisimus

    I guess I can put it in the config file... or maybe no protection against admins... why exactly don't you want the block protection?
     
  25. Offline

    Hant

    Museum_eingang;0;0;0;0;Hant;JagdGebiet;492;72;168;
    491:72:169;
    Museum_ausgang;0;0;0;0;Hant;JagdGebiet;490;72;168;
    491:72:167;
     
  26. Offline

    zwarmapapa

    Because we got a plugin that takes care of block protection already, if people make a turnstile in someone's town or house, the owner of that town/house can't destroy it.
    Please make an option to turn the block protection off, so that everyone can destroys everyones turnstile, when it is on their property.
     
  27. Offline

    Marco van Dijk

    Hey, does anyone know if paying with items is broken?
    when i type /ts price underwater1 264 1 it will give me the message that it will cost 1 of 264 to open it but it will just open anyway.
     
  28. Offline

    Codisimus

    Are you trying to open it with a button?
     
  29. Offline

    Mattie112

    When i do: "/ts price test 0" (to set it from 10 to free) it gives me this error:
    Code:
    18:24:14 [SEVERE] Could not pass event PLAYER_COMMAND_PREPROCESS to Turnstile
    java.lang.NoClassDefFoundError: cosine/boseconomy/BOSEconomy
            at turnstile.TurnstileMain.isBankOwner(TurnstileMain.java:202)
            at turnstile.Turnstile.isOwner(Turnstile.java:300)
            at turnstile.TurnstilePlayerListener.onPlayerCommandPreprocess(TurnstilePlayerListener.java:91)
            at org.bukkit.plugin.java.JavaPluginLoader$5.execute(JavaPluginLoader.java:182)
            at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:59)
            at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:255)
            at net.minecraft.server.NetServerHandler.c(NetServerHandler.java:637)
            at net.minecraft.server.NetServerHandler.chat(NetServerHandler.java:608)
            at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:602)
            at net.minecraft.server.Packet3Chat.a(SourceFile:24)
            at net.minecraft.server.NetworkManager.a(SourceFile:230)
            at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:76)
            at net.minecraft.server.NetworkListenThread.a(SourceFile:100)
            at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:357)
            at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:272)
            at net.minecraft.server.ThreadServerApplication.run(SourceFile:366)
    Caused by: java.lang.ClassNotFoundException: cosine.boseconomy.BOSEconomy
            at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
            at java.security.AccessController.doPrivileged(Native Method)
            at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
            at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:30)
            at java.lang.ClassLoader.loadClass(ClassLoader.java:323)
            at java.lang.ClassLoader.loadClass(ClassLoader.java:268)
            at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:336)
            ... 16 more
    
    CB560
     
  30. Offline

    Marco van Dijk

    Yes? Do i need to open it with something else?

    Edit: Im so stupid i read over the line with the chest, i figured it out now.
     
  31. Offline

    Codisimus

    no worries, im thinking of how i can make it easier...
    to clarify, your using BOSEconomy? wut version?
     

Share This Page