Spout.. hmm

Discussion in 'Plugin Development' started by A5H73Y, Oct 14, 2013.

Thread Status:
Not open for further replies.
  1. Offline


    So I thought my Parkour plugin would be nicer if linked with Spout but I cant for the life of me find a decent tutorial on how the API works. All I would want to do is display statistics to the screen (not even sure if thats possible) xD but I would appreciate a link to somewhere helpful :)
  2. Offline


    Well, why not visit their forums for help on the matter? Many of the Bukkit devs as well as the admins look down upon people using their forums for spout or forge.

  3. Offline


    Ive had a quick look before you posted that, it appears they havent even got around to updating it yet so I guess there is no rush in learning their API... xD
    But thanks reguardless
  4. Offline


    "Spout" can refer to at least two separate projects, in this context you were probably looking for the "legacy" projects, SpoutPlugin and SpoutCraft, which are a Bukkit plugin adding additional API, and a custom client to support said API, respectively. Many of the older threads on these forums regarding enhanced client support involve SpoutPlugin, since it was at one time a popular means to enhance Bukkit plugins beyond what is possible using the "vanilla" Minecraft client. But as of 1.6, the Spout project has officially discontinued this legacy project, in favor of their custom voxel game implementation, built from scratch (although IIRC there is an unsupported update, not familiar with it). It is similar to but completely distinct from Minecraft, it is not a Minecraft mod, nor depends on Bukkit or CraftBukkit (though they do have a BukkitBridge for some Bukkit plugin support I believe), so if you want to use it check out their forums instead. I have not used Spout myself but my understanding is that it is not as complete as Minecraft and/or CraftBukkit, though it definitely is an interesting project to keep an eye on.

    But back to your original problem. If you want to display additional information on the screen, it is certainly possible, but depending on how you want to do it may require client modification. First I'd recommend checking into scoreboards and see if you can display the information you need through that API, which will work with the vanilla client, no modifications needed.

    If you need something more powerful, as mentioned above there is Forge. However, it may be overkill for your purposes. The downside of Forge is you usually have to use it with a Forge server, as opposed to the vanilla CraftBukkit server. It is a great solution if you want to build sophisticated client/server mods, but for simply displaying a message on the client, I'm thinking there may be a simpler solution. You may want to look into LiteLoader instead. You can install it on the Minecraft client and use it to load simple client-side mods; the VoxelModPack for example uses it for mini-maps, in-game chat enhancements, client-side macro support. Displaying some simple statistics on the client is just about an ideal use case for LiteLoader. Best of all, it does not require any custom server implementation, you can use it with CraftBukkit servers, vanilla Minecraft servers, or about anything else.

    Now here is where Bukkit comes in. Early last year, Minecraft introduced plugin channels, which can be used to safely communicate between client and server, in a well-supported, clean fashion. Your client mod can register a plugin channel, listen for messages, and draw the text on the screen appropriately. Your Bukkit plugin can register the same channel, and send statistic updates. Admittedly I have not used this API but from what I can tell, you should be able to do this completely using the Bukkit API, no NMS needed. Look into PluginMessageListenerRegistration and the other classes in org.bukkit.plugin.messaging, should set you in the right direction. Maybe someone more familiar with plugin channels could chime in. Think @Mumfrey's VoxelModPackPlugin for Bukkit uses this API.
    Wulfspider likes this.
  5. Offline


    Wow thank you for such an amazing and extensive response! I would really like to look into these ideas for future projects but for a plugin that is as simple as Parkour it is not worth the time nor effort for little outcome. I have already integrated scoreboards to display their total deaths and have used the XPBar to show how far in the course they have progressed, but it would be nice to display their current time in the top corners or something :p
    Thanks again.
    agaricus likes this.
  6. Offline


    There are tutorials on the ol' wiki.spout.org, but they are most likely outdated. As agaricus said, the Legacy projects have been officially discontinued for future updates by Spout, but the projects are hopefully going to be continued by Dockter for the foreseeable future via spoutcraft.org (split from spout.org). I'm not sure what will happen for the updates, but it's possible that it may see a complete (and much needed) overhaul.

    If you have any questions though, feel free to ask on the forums linked above.

    It's mostly updated to 1.6.x, but there are a few things holding back releases for it. I'm not exactly sure on the details right now, as I am not involved with the updating process anymore really.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
    Last edited by a moderator: Jun 4, 2016
Thread Status:
Not open for further replies.

Share This Page