Comments (8)
is_in_water
checks if the entity's hitbox is fully submerged in water.
does it not work when the entity is fully submerged in water?
from cem.
Ah I see! Yes that does work! However, that is not how the Optifine code seems to treat that behaviour - Optifine's CEM checks whether or not the entity is touching water at all (rain doesn't count, just water sources and flow blocks).
Is there anyway to maybe apply this behaviour alongside what you currently have? For instance, when the mob is fully submerged - is_in_water
- one form of an animation can be triggered, where as when the mob is simply touching a water block (ie. not fully submerged, but floating atop of water like most mobs do when jumping into an ocean to follow you), another animation can be presented.
Bearing this in mind... I had an idea of trying something along the lines of is_in_water>=0.1
, but to probably no-one's surprise, that does not work as I assume this is a yes/no sort of value. Following this idea, I tried to potentially combine the idea of is_wet&&!is_on_ground
and that does actually work to the criteria of the creature being afloat of water... but this does mean that when a creeper is falling from a block or jumps off from a cliff while it's also raining, he will switch to a swimming animation...
So... any ideas how I could get around this problem? Are there any booleans that could detect rain? I can't find anything related to this. But thankyou for clearing this up to begin with! It'd be useful if there's a way to make the entity recognise rain defined by a separate boolean, that way I could have a "swimming" animation AND a "floating atop water" animation. Any help will be greatly appreciated...
Now to test whether or not Optifine recognises these boolean combinations the same way this mod does...
[edit]: Just tested these booleans within Optifine and they don't seem to like the is_wet&&!is_on_ground
combination when put up next to is_in_water
boolean... So I'm a bit puzzled at this point what to do as both versions interact differently with the booleans...
from cem.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs within 14 days. Thank you for your contributions.
from cem.
could you elaborate on the differences between optifine's booleans and this nods booleans?
how exactly are they different? I know you mentioned they behave differently but I'm having trouble understanding how...
They should behave the same since they check the same attribute on the actual entity
from cem.
To make it simple, Optifines CEM implementation of is_in_water
checks whether or not the entity is touching a water block (whether that is a source blocks or not), in comparison to your implementation, which checks for if the entity is fully submerged under water.
from cem.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs within 14 days. Thank you for your contributions.
from cem.
This sounds like a tough issue to crack, but then again I barely know simple code so everything code related is complicated to me
from cem.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs within 14 days. Thank you for your contributions.
from cem.
Related Issues (20)
- 0.7.2 not marked correctly on modrinth HOT 5
- Version 0.1.3 Missing Fabric Label
- [BUG] Broken when Sodium 0.4.9 HOT 1
- [BUG] issue
- [BUG] Crash on 1.19.2 HOT 2
- [BUG] Crash on 1.19.2
- [Suggestion] Mark 0.7.1 compatible for the right versions on Modrinth
- Dolphins? HOT 1
- [BUG] Could not start Minecraft 1.19.2 with CEM 0.7.3 HOT 1
- [BUG] mob heads texture not correct
- [BUG] Certain entity models from Lithos resource pack don't work correctly HOT 1
- Game Crashed with Vinery mod and CEM installed
- [BUG] 1.20 support HOT 1
- [BUG] CEM removes saved changes when exiting the game HOT 1
- [BUG] Incompatible with Litematica
- mark 0.8.0 as 1.20-1.20.1 on modrinth HOT 1
- [BUG] The .JEM Files Doesn't Work Correctly
- [BUG] Cat Body Floating When Sitting
- [FEATURE REQUEST/BUG?] Mobs that can be caught in buckets re-roll their custom textures
- [BUG] invisible entities HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cem.