Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make End Enderman have teleport cooldowns via configuration #41

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Burchard36
Copy link

Love this mod, but kinda got a little angry with these end enderman in ATM9 so I rage-added in cooldowns for End Enderman teleports, was going to just make this a suggestion buts its relatively simple so thought ide just make the PR my suggestions

Dunno much about how architectury works so I'm sure I might of not done something correctly for the /generated directory (I just manually added in my config-en_us line)

@@ -3,6 +3,7 @@
"config.endermanoverhaul.allowPickingUpBlocks": "Allow Picking Up Blocks",
"config.endermanoverhaul.allowSpawning": "Allow Spawning",
"config.endermanoverhaul.endEndermanTeleportChance": "End Enderman Teleport Chance",
"config.endermanoverhaul.endEndermanTeleportCooldown": "End Enderman Teleport Cooldown",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will be replaced every time datagen is run. Must be put in the ModLangProvider. then run datagen

@@ -128,8 +131,11 @@ public boolean doHurtTarget(@NotNull Entity target) {
if (super.doHurtTarget(target)) {
this.playSound(SoundEvents.PHANTOM_BITE, 10.0f, 0.95f + this.random.nextFloat() * 0.1f);
entityData.set(DATA_BITING_TICKS, 7);
if (target instanceof LivingEntity entity && random.nextFloat() < EndermanOverhaulConfig.endEndermanTeleportChance) {
final long currentTime = new Date().getTime();
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't use Date. Find the difference using tickcount.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants