Tuesday, February 2, 2016

Hippocamps and Seeing Underwater

Now that version 1.4.1 is out, riding a hippocamp lets you see underwater.  This works even in the dark, because the way I currently have it implemented, going underwater while riding a hippocamp triggers the Night Vision potion effect.

Special thanks go out to Adrian, who suggested I add the Night Vision potion effect to a hippocamp's rider.  It's a nice, easy solution to a problem that others had discovered while using the hipppcamp's otherwise awesome ability to let you explore underwater!

Even though giving the rider Night Vision is a nice way to solve a tricky problem, it still feels a little hacky to me.  The potion effect doesn't turn off right away, and it flashes the screen annoyingly when it does start to wear off (at least I think it's annoying).  Writing code to turn it off immediately when you come out of water is kind of complex, and may result in turning off legitimate uses of Night Vision potions, so I haven't done it yet.

The main problem is that the Minecraft code is written in such a way as there's no easy, central place to change the code so that it provides the Night Vision effect, without also changing core Minecraft classes.  For now, I'm avoiding changing core classes, just because it increases the likelihood that The Ultimate Unicorn Mod will break something when used with other mods.  Things break often enough with other mods that don't play nice, so I want to make sure to play nice! :)

I'll keep thinking about it, and if I come up with a better way to let players see underwater, I'll jump at it.  For now, though, this is a pretty good solution.

If you have any ideas, feel free to let me know in the comments!

8 comments:

  1. how do i summon/make a hippocamp?

    ReplyDelete
    Replies
    1. The easiest way is to use the command "/summon Hippocamp" . You can also find or summon a unicorn or other magical horse, then use a cheat code on it (take a look at the cheats page).

      Delete
  2. We are playing always fun. Thank you
    Do you have any plans to be ver 1.9?

    ReplyDelete
    Replies
    1. Good question! When forge releases a new version for 1.9, I will port the mod to that version, too. Unfortunately, I don't know when that will be. I will be watching for it, though!

      Delete
    2. I am waiting expectantly. ;)

      Delete
  3. Please make the new custom unicorn version for 1.8.9, because that's the forge i have and the java, too so please change the new update availibilities to 1.8.9, too.

    ReplyDelete
    Replies
    1. I have already released a version for forge 1.8.9. Is it not working? I have not put out a 1.9 version yet, though.

      Delete
  4. Hello there! I have been playing with you mod and I love it very much. I do have a few bugs to report! Would you like a list?
    Oh and how can I support this mod? I have a few ideas, if you are open to them. Thanks for your time!

    ReplyDelete