Jump to content

GhostWolf2398

Members
  • Posts

    5
  • Joined

  • Last visited

Everything posted by GhostWolf2398

  1. Hello. I would like to preface my post by saying that I am a Senior Developer of the Pixelmon mod, and that we have recently transitioned our Pokemon spawning from using just biomes to utilizing the BiomeDictionary system, to allow for greater compatibility with other mods. While the dictionary is a good system for cross-compatibility of mods with biome generation code, we have found that it could use a few tweaks for maximum compatibility. The major issue we have encountered is that it isn't possible to differentiate River and Ocean style biomes from tags alone (both are [Water] or [Water, Frozen]). I would like to propose possibly differentiating the WATER tag into RIVER and OCEAN (possibly retaining the WATER tag as referring to either for compatibility, but it may be necessary for mods to adapt to the new tag split). This would allow for the following vanilla initilization: BiomeDictionary.registerBiomeType(river, RIVER); BiomeDictionary.registerBiomeType(ocean, OCEAN); BiomeDictionary.registerBiomeType(frozenRiver, RIVER, FROZEN); BiomeDictionary.registerBiomeType(frozenOcean, OCEAN, FROZEN); A secondary improvement on the dictionary is the way vanilla biomes are classified and initialized in Forge. In particulare the icePlains and iceMountains (both just [Frozen]), and the hills sub-biomes (which lack the HILLS secondary tag). I would propose changing the initialization to the following: BiomeDictionary.registerBiomeType(icePlains, FROZEN, PLAINS); BiomeDictionary.registerBiomeType(iceMountains, FROZEN, MOUNTAINS); BiomeDictionary.registerBiomeType(desertHills, DESERT, HILLS); BiomeDictionary.registerBiomeType(jungleHills, JUNGLE, HILLS); BiomeDictionary.registerBiomeType(forestHills, FOREST, HILLS); This initialization still allows for each biome to be identified correctly by mods that use isBiomeOfType() calls, and provides additional specificity for mods that want to differentiate the hills portions and the two ice biomes. I realize that some of this may end up changing slightly with the new 1.7 and beyond biomes, but hope that this would improve the BiomeDictionary system in its current state.
  2. That makes a lot of sense. I was thinking you were suggesting only making the dismounting code inside the mount's code, and not doing the check at that line in the entityLivingBase code, since that wouldn't change things. With the way you have it, it would give the ridden entity the control over kicking, which makes it more generally customizable, and it will make the check at the right place in code, so that is the best solution to the issue. Thanks for your help and insight.
  3. This is the location in the code that causes the issue with underwater riding. Based on your comment, I looked at putting something inside the mountEntity() function, but that is only called when you change from mounting to unmounting, and that boolean variable if used there could cause other behavioral issues (such as never letting you get off the mount, etc) The line I placed the check at is the only point at which you would want to circumvent the normal unmounting code for this kind of problem, as it is the only point where the unmounting is caused by the rider being located in water. By locating that boolean check there, you only get the bypass behavior under that one condition, and riding should behave entirely normally for all other situations. If you meant a function in the code of the entity being mounted, it likely wouldn't solve the issue we are having, as it is this particular point in the code where it forces the unmounting, and any other function in the mounted entity that would say force re-mounting would be run too frequently while under water to be an elegant solution to the issue. Hopefully that makes sense, feel free to correct me if I am wrong.
  4. I went ahead and wrote in the needed code. I can't get the patches to update or commit correctly to github, so here is the code for someone who can do that, all written out for you (red text is added, the rest is just to help you locate where to put it). and
  5. Hello, I am GhostWolf, one of the coding developers for the Pixelmon mod (essentially Pokemon in Minecraft). We were wondering if it would be possible to add an event into entityLivingBase that would allow us to specify custom behavior for when a player rides an entity underwater. We currently have several mounts that are capable of surfing and diving, and with the code in entityLivingBase lines 281-309 (and 305-309 in particular), as soon as a player goes fully underwater they unmount (whether it is just the natural up and down swimming on the mount or actually diving). Ideally we would be able to just override this or change the event response to this so that the player can remain on the mount. Any help and suggestions you can give on this would be greatly appreciated. We would also be more than happy to take care of the needed coding if you had the way this should be done figured out.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.