[MISC] WeatherSync v2.0_1 - The real-world weather - Now with multiworld and more! [1337-1597]

Discussion in 'Inactive/Unsupported Plugins' started by cppchriscpp, Apr 22, 2011.

  1. Offline


    Moving to BukkitDev! Click here!

    WeatherSync - The real-world weather in Minecraft
    Version: 2.0_1

    Important note for those upgrading from 1.2: Your old configuration files will not work as-is. You'll need to copy over the new config file, and move over any old settings that still apply.

    This plugin keeps the weather in the worlds on your server synchronized with the real-world weather in a location you specify. It does this by connecting to weather underground every few minutes (configurable; 5 minutes by default) and parsing the weather. This means if it's raining outside, it will be raining in minecraft. This is also true of thunderstorms.

    You will want to configure it before you try to use it; otherwise it will synchronize your default world (named "world") with the weather in San Francisco, California. (Used for testing.)

    This should work for any place you can get an RSS feed with weather in it from WeatherUnderground. See the directions below for how to find this, and if it does not work, feel free to ask for help. Please be sure to provide the URL you are using!

    RSS feeds are now the only way to synchronize with this plugin. Old location information will be ignored by the plugin as of version 1.3.

    You can now view the forecast with the /forecast command, which is available to all users. It will also show the current weather. This command can be disabled, if desired.

    As a warning, I have not been able to test this to the level I test most things due to the nature of it. Please let me know if/when you have issues.

    Download (Source code is in there too!)

    Future Features:
    • Heavy/severe thunderstorms? (Sorry guys, there's no chance I'm going to have time for this. Maybe another plugin can hook into thunderstorms and make this happen, if it doesn't already exist.)
    • unit selection (determined by rss feed; see the ?units=metric/english at the end? change that)
    • None; I implemented everything else here! :)
    Time synchronization:

    Some people in this thread expressed interest in having the real world time on their servers alongside this. I was going to code this myself, however there is something out there already that can do this. Check out RealTime by Mechestrial for this!


    How to find your RSS feed (open)
    This plugin now asks you to provide the URL to an RSS feed to get the weather. The old method will not work past version 1.2. The method to get the URL to your RSS feed is as follows:

    Navigate to http://wunderground.com, and find your location.

    Around the height of the title of the page on the far right is an RSS icon. You need to get the URL of this -- right click it and copy the link address. It should look like:
    Take this entire thing, and put it in the worlds section of your config file.

    If you have problems finding this, just ask. My explanation here is not that good.


    Due to how this thread has been going, I am going to require all reports to include this information, or your bug report may be ignored.
    • An extremely detailed description of the problem.
    • That you have turned debug mode on in the config file, and then caused the problem to happen-- this will provide me with helpful insights into what is going wrong.
    • Your configuration file
    • The major error that occurred
    • The rest of the server.log surrounding that error. If you aren't sure, just give me the whole thing.
    • Any errors a client might have seen
    • Anything you think might have gone wrong -- your insights often lead me to the problem quickly; even if you are wrong.
    • Your build of craftbukkit
    • Any changes in your setup that preceeded the problems (installed plugins, mainly)
    • Your system information (Some of this is in /debug info)
      • (Ideally, just include all output from these two commands.)
      • Operating system
      • Java version
      • Any wrapper software you might be using
      • A list of plugins you use (As reported by /plugins or "plugins" at the server command line)
    • Any other details that could be relevant.
    Yeah, I know it's a lot and it's kind of a pain in the rear. Some of it won't be useful in some situations, but I only get a very little time to work on this now, and I really don't like having to put that time to waste just because I don't have all the information I could about what went wrong.


    Version 2.0_1
    • Fixed a dumb mistake causing some users to get the forecast for the last day available instead of the first.
    Version 2.0
    • Multiworld support!!!!111 (Sorry; had to do it.)
    • Re-enabled messages to users on the weather changing
    • Redid the configuration file for multiworld and some other stuff
    • Customization options for messages; you can now set what the plugin sends to users!
    Version 1.3
    • Never existed; I jumped straight to 2.0. Not sure what I was on when I put this version here. >_>
    Version 1.2
    • Fixed (hopefully) the bug with weather not updating once and for all. The weather will be FORCIBLY updated every time the weather is checked.
      • Note that client desynchronization issues may still occur. If you disconnect and reconnect and the weather is correct again, there is nothing I can do to fix this, sorry.
    • Changed the default method of specifying location to an RSS feed. Let's see how this can break things D:
    • Accidentally removed the show-forecast option which shows when the weather changes in chat. Did anyone actually use this? Redoing it for multiworld is going to be a massive pain if people want it.
    • Fixed broken forecasts
    Version 1.1_3
    • Fixed debug mode -- anyone who had problems please try again and report your issues again. Sorry for the inconvenience; it was my fault.
    Version 1.1_2

    • Fixed the weather randomly changing bug. Really this time! (I think)
    Version 1.1_1

    • Program now accepts blank configuration options correctly
      • (This fixes the null pointer issues.)
    Version 1.1

    • Weather forecasting (w/ forecast command)
    • Ability to show forecast on join
    • Debug mode that will display what the weather is on start and when it changes (new config option -- use this to report bugs!)
    • More failure-checking in the forecast changes.
    • Support for weather stations
    • Fixed threading/recursion..
    • Clarified config files.
    • Fixed various bugs
      • Weather duration not being set (cause of random weather at times)
      • Improper string conversion (That boolean bug that someone had on page 4)
      • (More that have been forgotten since being fixed..)
    Version 1.0

    • Initial release
    JonasD, zhuowei, Stoepsel and 5 others like this.
  2. Offline


    Okay, with the current version (and the rss method) the forecast seems to work. I'll test if the weather stays synchronized now. :) Thank you so much, this really is an awful plugin!
  3. Offline


    Owch :(

    Also, thanks for reminding me. I also fixed forecasts in the most recent version, but I for some reason forgot to add that to my change log. Updated the first post.
  4. Offline


    The plugin seems to work, but I still have issues with clients getting out of sync. It seems to happen to all players on the server simultaneously. Reconnecting clears the "bad" weather. I'm pretty sure this isn't the plugin's fault, as I've seen it happen without the plugin as well. Is anyone else seeing this, or is it just me?
  5. Offline


    I've seen it a couple times, and I looked for any way to send the weather to the client, but I can't find any way without hijacking all weather from CraftBukkit and sending it to the clients in raw form. Another plugin actually does that, and the results are really cool. I might try doing that at some point, but I'd really prefer being able to do it through the API. Otherwise, the plugin will be very likely to break with every update, from what I hear.

    In short, not much I can do, but I've seen it.
  6. Offline


    I can't handle the source. I want to change some values (like degrees) into german, but if I compile the .jar file, put it into the "plugins" folder and say /forecast, it gives me an internal error. I am using Eclipse ATM.

    thanks in advance,

  7. Offline


    I've replied to your email; hopefully I'll be of some help. If you want degrees in german, you might be able to get the rss feed you're using to change languages; I haven't explored if this is possible, however. If you want to translate the entire thing, that should not be too difficult. Let me know if you have more issues.
  8. Offline


    It's currently raining in my server. The forecast says that is partly sunny, and it is true when I look out my window. Help?

    EDIT: Restarting my server fixed it, yet I didn't change any config. Perhaps the mod is not correctly stopping the Weather change (Dunno the exact name) event?
  9. Offline


    Did you try disconnecting and reconnecting first? The client & server sometimes get out of sync. If that's not the cause I have no idea what is. I literally change the weather to be exactly what the forecast says every 5 (default) minutes. Unless I'm missing something obvious, there's nothing more I can do to make it more correct.
  10. Offline

    Don Redhorse

  11. Offline


    I'll look into that a bit later; I thought I got all of the buggy forecasts dealt with. To be sure, you did update to the latest version, right?

    As for worlds, you set the name of the world as the world variable in the config. As it says in the first post, real multiworld support is still a work in progress.
  12. Offline

    Don Redhorse

    ahh... thought you already had the multiworld done.. sorry about that... I think I have the latest version but I will check again.. 1.2 it says when loading...

    working now... hmm.... don't know why... it shows temperatures in fahrenheit though..

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


    No idea, but you can change it. See the ?units=stuff thing at the end of your rss file? Change it to ?units=metric and see if that works.
  14. Offline

    Don Redhorse

    will do, was already wondering what meictr does..
  15. Offline


    I get this error when I type /forecast

    2011-05-22 23:27:36 [SEVERE] null
    org.bukkit.command.CommandException: Unhandled exception executing command 'forecast' in plugin WeatherSync v1.2
    at org.bukkit.command.PluginCommand.execute(PluginCommand.java:37)
    at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:127)
    at org.bukkit.craftbukkit.CraftServer.dispatchCommand(CraftServer.java:279)
    at net.minecraft.server.NetServerHandler.handleCommand(NetServerHandler.java:699)
    at net.minecraft.server.NetServerHandler.chat(NetServerHandler.java:666)
    at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:660)
    at net.minecraft.server.Packet3Chat.a(Packet3Chat.java:32)
    at net.minecraft.server.NetworkManager.a(NetworkManager.java:196)
    at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:75)
    at net.minecraft.server.NetworkListenThread.a(SourceFile:100)
    at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:377)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:292)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:394)
    Caused by: java.lang.NullPointerException
    at net.cpprograms.minecraft.WeatherSync.WeatherSync.onCommand(WeatherSync.java:199)
    at org.bukkit.command.PluginCommand.execute(PluginCommand.java:35)
  16. Offline


    I've been trying, and I can't recreate that, or even figure out how that could happen. Try restarting the server. If that fails, please provide some of the information I request for bug reports..

    Also does the plugin function normally otherwise?
  17. Offline


    It tells me that it can't load the config file, I have completely removed it and let it generate it and still get the error
  18. Offline


    It doesn't generate one. You have to put it there. Reinstall the plugin, and edit the configuration file to suit your location.
  19. Offline


    I have twice and it still says that. ill paste it in
  20. Offline


    Since that's a version of the configuration file that hasn't been supported since the latest update, I have a hard time believing that you really reinstalled, or deleted the folder/file like you said.

    Please update to the latest version from the first post if you have not already. (The console should show WeatherSync version 1.2 loaded at startup.)

    After this, please update your configuration file to use the new format. You'll need to get the RSS file representing your weather from the first post for this. (This step is not strictly necessary to get it to work, but if you need additional help, you'd better have done this.)

    After this, try running the server again with the plugin. If you still have problems, please include the information stated in the first post that I asked you for. For your convenience, I am quoting it here.

  21. Offline


    From the 1.6 patch notes:

    * Fixed weather sometimes changing client-side in multiplayer

  22. Offline


    Awesome; I hadn't actually noticed that yet. I like the list of changes, though it seems like the invincible pigs are still going to be present. *sadface*
  23. Offline


  24. Offline


    Well, that's what the site's forecast supplies. Not much I can do about that, sorry. :(
  25. Offline


    But on the site it saíd that it was 17 degrees, yet it still shows 9! Or is that in fahrenheit or something?
  26. Offline


    It's the forecast for the day, not the current weather.
  27. Offline


    Oh... that's pretty obvious *facepalms hisself*
    Sorry XD
  28. Offline


    No worries, I was just kind of confused at what you meant for a moment.
  29. Offline


    Lol :p
    I seriously hope beta 1.6 is coming soon, the client side rain is quite irritating.
  30. Offline


    Last I heard tomorrow or thursday, so soon!
  31. Offline


    Can't wait :)

Share This Page