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

Inter-Mod Communication stuff #165

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

cosmicdan
Copy link

So here's that thing I was going to do. Works perfectly for our purposes, but let me know if there's something you want done differently.

@cosmicdan
Copy link
Author

Oh, it might be a bit useless without a world object to work with in the event. Added.

@cosmicdan
Copy link
Author

Hrrrrr..... added one more event that's fired a bit later, allows filtering on CreatureType. Last commit, I promise!

@cosmicdan
Copy link
Author

Oh, I completely forgot - you wanted this to be optional and disabled by default. I'll work on that.

I also wanted to add something else, also off by default obviously. This...
entity.getEntityData().setBoolean("JAS_SPAWNED", true);
...to every entity that JAS spawns. This is also for Inter-Mod Communicaton, so other mods can check if a particular entity was spawned into the world via JAS instead of some other method (like spawner machines). In our use case, we have a "score" related to mob kills to accrue only when naturally-spawned mobs are killed to prevent players farming that "score" through e.g. mob farms.

I'll put all of this in a separate "IMC.cfg", with the two options - 1) Fire spawn events and 2) Add entitydata flag - located here, both false.

@cosmicdan cosmicdan changed the title Add "AddEligibleChunkForSpawning" forge event Inter-Mod Communication stuff May 15, 2017
@cosmicdan
Copy link
Author

Ok that's done. Let me know if you want anything changed for the PR.

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.

1 participant