lenis0012 / npcfactory Goto Github PK
View Code? Open in Web Editor NEWNPC Library for CraftBukkit mod.
License: MIT License
NPC Library for CraftBukkit mod.
License: MIT License
If an NPC is right clicked, using this event will not do anything, instead you have to get the entity by the PlayerInteractEntityEvent and checking the entity that is right-clicked has the 'NPC' metadata.
When an NPC is spawned its CraftPlayer is given the "NPC" Metadata. When a real CraftPlayer instance (actual player) is checked for the 'NPC' metadata, and an NPC has the name of the player, then it returns true. This is due to the way Player metadata is stored, it's stored 'name:key', this is a rather big issue and can easily be prevented.
Override the NPCEntity's CraftPlayer PlayerMetadataStore to store by entity id or something.
when checking for isNPC, return entity instanceof NPCEntity
I'd recommend the former.
Hi lenis! thanks for your library to create npcs!!!
I have a problem :S im using ur NPCFactory version for spigot 1.7.9 and works great, but i have a problem. I need add invisibility potion effect to a npc, but it doesnt work...
PotionEffect potion = new PotionEffect(PotionEffectType.INVISIBILITY, Integer.MAX_VALUE, 1);
npc.getBukkitEntity().addPotionEffect(potion);
what can i do? :s:
Thanks
The custom NPC does not take damage from ignited fire or lava for example, only when attacked by another entity.
I've set the damage event to not cancel. I've also set the NPC to non invulnerable.
--
Thanks
It would be nice if there was an option to hide or show an npc for a specific spectator.
the current version is for Spigot 1.8.x and i need for 1.10.x so please update it, i really love it !
I'm having this problem and I do not know how it came to be
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.