Inactive [TP] xWarp v3.1.7 - MyWarp fork (w/ prices, economy, visibility) [1.2.5-R1.0]

Discussion in 'Inactive/Unsupported Plugins' started by xZise, Jan 17, 2011.

  1. Offline

    xZise

    Hello everyone,
    I forked the MyWarp project and added some functionality. In basic it is the same as the MyWarp.

    Now on BukkitDev
    This plugin is already on BukkitDev. I will transfer this post to BukkitDev.

    Download
    3.1.7 + marker (Tested: 1.2.5-R1.0)
    3.1.7 (Tested: 1.2.5-R1.0)
    2.12.0 (Tested: cb819, Should run ≥ cb691)
    All downloads

    The versions for other builds are normally only compatibly updates. So they don't provide other features. This means version “a-cb684” is the same (in basic) as “a-cb556” or simply “a”.
    Notice: With version 2.3.0, 2.6.0, 2.8.0, 2.9.0, 3.0.0 (or later) I changed the database layout. Previous versions of xWarp couldn't read this database. So backup it for sure.

    Ressources

    Changes
    Changelog moved to BukkitDev. The full changelog is still on github.

    Prices
    Since 2.8.0 it is possible to use prices for warp and creation. It uses the Permissions nodes to change define basic prices. Also it is possible to define a price for each warp. At the moment iConomy version 4 and 5, Essentials Economy (at least Dev build 2.2.104) and BOSEconomy supported.
    Global/Public/Private warps
    With the Version 2.0.0 beta 13 I introduce the new state of global warps. Every user can create warps for its own (public/private) like before and hasn't be aware of already existing one's from others. So Player “A” could create a warp named “foo” and another Player “B” could also create a warp called “foo”. Now to access these warps you have to specify which warp do you want to use.
    Therefore I added a parameter to specify the owner of the warp. To warp to the “foo” warp of Player “A” you simply type:
    /warp foo A
    You could exchange the second parameter (= A) with a B to warp to B's warp “foo”.
    Now to shorten the warps you could globalize a warp with
    /warp global <name> <owner>
    Now you don't have to add the owner of the warp. For example if somebody globalized the warp “foo” of player “A” you now can simply type:
    /warp foo
    There is one rule: “If you don't define the owner it searches the global warps.”
    But a global warp also has a owner (in our case Player “A”) so you also define the owner.
    So there is one major change: If your warp contains a space you have to escape it, otherwise it will guess the second part as a owner (to escape see the section above).
    For further information visit the wiki.
    Sign Warps
    Creating a sign warp is really easy. You have 3 layouts: MyWarp, Single Line and xWarp.
    In MyWarp your sign has two lines. In the first place only “MyWarp” and in the second the name of the warp. This works only if the warp is in the global map.
    The “Single Line” layout only needs a line with “Warp: <name>”. If there are more than one lines with this layout on one sign it won't work. The colon is optional, the W could be lowercase and the spaces between “Warp:” and the name have to be at least one.
    With xWarp layout you could place “xWarp” in the first line (case-insensitive) or “Warp”/“warp” and optional a colon.
    In the second line is the name of the warp and in the third the owner (optional)
    Upcoming changes
    Backups? (unknown)
    If possible I maybe make it possible to backup the warps with others backup plugins. It is only an idea at a moment, but maybe sometimes xWarp supports this.
    tkelly's suggestion system (Suspended)
    tkelly created a system, that can get a warp similar named if you didn't spell it right.

    Fabian aka xZise
     
    RazorFlint, Taranis01 and uitology like this.
  2. Offline

    chill1977

    So basically all of the changes you made to tkelly's mod are untested and may not even be working but yet you post it here?
    --- merged: Jan 17, 2011 11:37 AM ---
    that's what the plugin dev forum is for i believe
     
  3. Offline

    xZise

    Hello,
    I will do my best to make it more stable. I haven't enough private warps to test the number of pages. I have a running server without a warps.txt, so the testing of the importing is complicated.

    But I tested it and the private warp thing works. You can also warps to other places ignoring the lower/upper case. There is one problem, when you creating a warps which already exists but in other combination of lower/upper case. (Only if you wrote it in lower case won't work)

    Sincerely
    xZise
     
  4. Offline

    ledhead900

    Dude I think thats a + for features leave it like that !, That stops accidently same name different place warping issues, If u fix that I can see ppl complaining about how they typed This but endup at that.
     
  5. Offline

    xZise

    Hmmm,
    okay I tested the last untested feature (importing) and it seems to work for me. And I fixed the bug, that somebody could create a warp with the same word in another lower/uppercase combination. (Fixed in 1.6.6)

    Both (source/jar) are updated.

    Sincerely
    xZise
     
  6. Offline

    Gimmic

    xZise, could you make it so the blockid is configurable from the properties file? I tried to do it myself but am having problems compliling.

    Edit: nevermind. my post is in regards to WarpGate. Source is provided, think you could take a look at that one?
     
  7. Offline

    xZise

    @Gimmic :confused: I'm sorry, but I created xWarp, because I used MyWarp on my own server. But I answered you in the WarpGate-Thread.

    So now I uploaded a untested 1.6.9 alpha jar. There are several changes within, but at the moment I wasn't able to test them.

    My next step will be a possibility to set the welcome message. But therefore I had to create a little parser.

    Sincerely
    xZise

    Okay I tested every feature of 1.6.9 (for short time this was uploaded) and added a new feature to set the welcome message for the warp :) I now added a simple parser (detailed description is in the first post).

    Fixed bug, that some methods weren't case insensitive in 1.6.11!

    Sincerely
    xZise

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

    Drakonas

    When I type /warp help in Bukkit #66, my client crashes.

    Here's the client-side exception: (nothing server-side)
    Code:
    java.lang.StringIndexOutOfBoundsException: String index out of range: 37
        at java.lang.String.charAt(Unknown Source)
        at nh.a(SourceFile:152)
        at nh.a(SourceFile:119)
        at pe.a(SourceFile:238)
        at ll.b(SourceFile:369)
        at net.minecraft.client.Minecraft.run(SourceFile:705)
        at java.lang.Thread.run(Unknown Source)
    This may be an issue with Bukkit, but I think it can be fixed by you.
     
  9. Offline

    xZise

    Hello,
    I'm sorry, but the last message was buggy. I fixed it in 1.6.12!

    Sincerely
    xZise
     
  10. Offline

    xZise

    Moin,
    I now updated it to 1.6.16 which now shows a message when you update a warp. I also could test every feature.

    Sincerely
    xZise
     
  11. Offline

    xZise

    Hello,
    at the moment I'm working on supporting Permissions. But at the moment the jar crashes when it doesn't exists. So if you don't use Permissions use 1.6.16 instead.

    Sincerely
    xZise
     
  12. Offline

    FabianN

    I think I'll wait till this is a little more stable and bug free but looks great. One thing I am wanting though is an option to force it so that all warps that are created are private by default and then the user can make them public if they wish.
    Would allow my users to create lots of warps for themselves without thinking about it (like most do) without clogging up the global warp list.
     
  13. Offline

    xZise

    You could already do it in my implementation with "createp" or "+p". In MyWarp it is available via "pcreate". And with permissions you could deny the users to create public warps.

    Okay one possibility is to add a permission, that only allows to create private warps but also allows to publicize them.

    Sincerely
    xZise

    Okay now it should run without permissions like before (everybody can create, owner can edit them, op can do everything).

    Sincerely
    xZise

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

    xZise

    Okay new permission(name)s and a new feature are now up to date (1.7.2).

    Sincerely yours
    xZise
     
  15. Offline

    xZise

    Is is now updated to 1.7.7 because of problems with the permissions system. Also the manifest was incorrect and didn't load the sqlite library. This library has also been placed into the lib/ folder.

    Fabian
     
  16. Offline

    xZise

    So update to 1.8.0 b1. So you could now use MyHome and xWarp at the same time.

    Fabian
    --- merged: Feb 7, 2011 9:09 PM ---
    Okay today I added global warps. More in the starting post.

    Please don't use MyHome and xWarp together because then it isn't possible to write into the database.

    Fabian
    --- merged: Feb 8, 2011 6:08 PM ---
    I uploaded beta 14 today, because of some minor changes (see changelog).
    --- merged: Feb 8, 2011 7:02 PM ---
    Oh no :( /warp global didn't work (or correctly told: it wasn't recognized). So I uploaded beta 15. If I don't find any bugs more it will be stable soon.
    --- merged: Feb 10, 2011 1:23 AM ---
    Okay now I quickly added sign warps (thanks to tkelly for publishing your code!). This will read MyWarp sign and introduce new xWarp signs. More in the first post.

    I also removed beta because sign warps seems to work for me, and I don't see any bug in the new global system.

    Fabian
     
  17. Offline

    Bolerodan

    I noticed you mentioned you're not sure how to store the world the warp is in. After taking a look at your source code, you're on the right track. I modified and recompiled your code and was able to get warps to work correctly between worlds. (you had the code already there, just commented out). Then i changed the Database scheme for the world entry to "string" as this will hold the worlds name (string), since we will use the worlds string name, to retrieve the world object back. The only problem that occurs is the console has errors of "player moved wrongly" however that is known, and there is a thread about that here, although this uses OnPlayerMove, so this fix may not be possible.

    http://forums.bukkit.org/threads/player-moved-wrongly.3734/

    another suggestion is to have the warps that are added mid game, become automatically accessible, so the players do not need to type "/warp reload" constantly. What I did was just call your warp reload function after each event(create, update, delete, etc) so the warps become automatically useable, however I dont know if this is the best practice to constantly reload the database in that manner. It works, but again Im not sure if thats best.

    Cheers!
     
  18. Offline

    xZise

    Hello Bolerodan,
    with the “player moved wrongly” problem I also found this thread, but at the moment I want to be sure that I implement it the right way.

    One problem is, that the name (if you rely on the javadoc) hasn't to be unique (Javadoc).

    The other think with “warp reload”: I don't understand what you mean, because this will only load the warps from the database into the RAM. But if someone create a new warp it will add into the RAM and saved into the database. You can verify this in the class WarpList. This calls the method “putIntoPersonal(Map, Warp)”.

    But thank you that you revisited my code :)


    Fabian
     
  19. Offline

    Bolerodan

    Hey xZise

    Hmm.. I thought they re-worked that so it would be unique, I guess im not 100% sure how they implemented naming a world when it is created. I assume that a world is given a name, and that name is used as the directory name for the world.. making it impossible to have duplicate names. Atleast thats how I see it in my head.

    I suppose I explained the reloading thing wrong haha my bad. So what I mean is (with your vanilla code, not my modifications) I add a new warp called "NewWarp". If I then do a List command to see the available lists, it is NOT available, until I initiate the /warp reload command. Once I reload, the warp becomes available in the list and I can then warp to it.
     
  20. Offline

    xZise

    Okay, and how do you add the new warp?

    Fabian
     
  21. Offline

    Bolerodan

    with the command "/warp create NewWarpName"
     
  22. Offline

    xZise

    Okay I tested it on my own: You are correct that the new warp doesn't shows up in the list. But a /warp reload doesn't change anything. And you could use this warp, its simply not shown on the list. I think the bug is in WarpList.getSortedWarps().

    And it seems like non global warps (which you created) are don't stored in the global list. So to use it you have to define also the creator:
    /warp NewWarpName <name of creator>

    Fabian
    --- merged: Feb 12, 2011 3:46 PM ---
    Okay today I fixed your bug in version 2.1.7 Bolerodan that new warps wasn't shown on the list.

    Fabian
     
  23. Offline

    ethernity

    Is your Plugin working with the new Multiverse/Nether Plugins?
     
  24. Offline

    jaybud4

    Supposedly, but running on 318 and 2.1.7, the entire plugin seems to be broken.
    I can create warps with +p, but none of the other commands work.
     
  25. Offline

    xZise

    At the moment not, because I'm unsure how to save the world in the database and how to fix the “moved wrongly” bug.

    That's strange. Is there any output on the console? Do you use the permissions plugin (which version)? Because on my server its running without a problem (same build).

    Fabian
     
  26. Offline

    jaybud4

    Specifically, it was trying to parse the commands as warps. "No such warp 'help'", etc.
    EDIT: Still happening with 2.2.0.

    "No such warp 'help'"
    No errors, Permissions 2.0
     
  27. Offline

    xZise

    Do you use essentials? Maybe this conflicts with xWarp. And what permissions do you/the user have?

    Fabian
     
  28. Offline

    jaybud4

    No, I use General.
    As for permissions, I'm admin, so wildcard (*).
    Other plugins I run include MinecartMania (Core, Sign Commands, Stations, AdminControls), MultiVerse, iChat, properTime, WorldGuard, WorldEdit, vStopFire, Minequery, CraftIRC, and MCDocs, although I'm reasonably certain there's no /warp functionality in any of those.

    EDIT: /warp delete test =>
    Code:
    SEVERE: Could not pass event PLAYER_COMMAND to xWarp
    java.lang.NullPointerException
    at me.taylorkelly.mywarp.WarpList.deletewarp(WarpList.java:150)
    at me.taylorkelly.mywarp.WMPlayerListener.onPlayerCommand(WMPlayerListener.java:152)
    ...
    
     
  29. Offline

    xZise

    Hello, that is strange. Here on my server it works great. I have placed one notification into this build. It sends a “to” to you, if it calls my function. One note: This will update the database layout! Please make a backup of “homes-warps.db” before you start the plugin.

    UPDATE: The attached file is now updated. You will get every segment of the command. So “/warp help” should print two lines:
    Code:
    /warp
    help
    Fabian
     
  30. Offline

    jaybud4

    /warp help
    Code:
    0=/warp
    1=help
    to
    No such warp 'help'
    /warp +p test
    Code:
    0=/warp
    1=+p
    2=test
    Successfully created 'test'
    You have privatized 'test'.
    
    /warp delete test
    Code:
    0=/warp
    1=delete
    2=test
    No such warp 'test'
    
    /warp list
    Code:
    0=/warp
    1=list
    ----- PAGE 1/1 -----
    'test' by you   @[coords]
    
    No NPE anymore, but still incorrect functionality.
     

Share This Page