Closed valleydev closed 7 years ago
AI/movement design has not been decided on yet so there is no class or place yet but pulse seems like the best idea.
Mobs don't automatically spawn. You can use a spawn egg or the spawnEntity()
method in GlowWorld
.
Thanks for your response. I will have a look at the GlowWorld.spawnEntity function and the Pulse quene.
Further questions: Is there dangermap (dangerous areas = high value) or A* pathfinding implemented?
There is no AI per say in Glowstone, and mob spawning is not implemented in world generation. I have an A* pathfinding library repo on my account, but it would need some tweaking for 3D environments.
The closest to a dangermap is canSpawn()
in the generator classes (GlowChunkGenerator
, NetherGenerator
, TheEndGenerator
). But it's not really an actual solution.
Some strange behaviour:
i put
if (true) return false;
in the first line of function
GlowCow.entityInteract
but i am still able to milk the cow in survival mode.
Where is the milk etc. logic implemented??
i noticed that killing an animal (spawned by an egg) does not drop anything.
Log out and back in and see if the bucket is still milk. It may be a client issue expecting to be able to milk the cow, and it then desyncs from the server, because GlowCow.entityInteract()
is where the milking functionality is located.
There are no entity death drops implemented.
dropping for cow implemented.
any suggestions on how to make a pull request? do i need to create a new branch first?
Here's where you can find everything you need to know about helping with Glowstone's development:
https://github.com/GlowstoneMC/Glowstone/wiki/How-to-Help#developing. Make sure you also read the Contributing and PR Handling pages linked at the bottom of the section, please.
Also, our Contribution policy explains some more details about our contribution process. It's not a CLA or anything you have to agree to, just how contributions are managed.
**Also hop on our Discord if you want to chat about development!
i have created a pull request. (so far some animals are dropping items) Missing: Dropping Experience Missing: Dropping grilled Chicken flesh anfter animal has been ignited
Room for improvement.
Any idea how to move an animal from the pulse function? Just set the position?
Closing in favor of #390.
I am not sure if animals are currently implemented. Currently they are not spawning on my test server.
This is the class hierarchy of the wolf which i found in source code
GlowEntity (Entity) GlowLivingEntity GlowCreature GlowAgeable net.glowstone.entity.passive.GlowAnimal net.glowstone.entity.passive.GlowTameable net.glowstone.entity.passive.GlowWolf
How can i spawn an entity?
Please correct me if i am wrong: GlowWolf wolf = new GlowWolf(); [instance of GlowWorld].entities.register( wolf );
Anything else need to be done?
Which class is responsible for making the animals move?
pulse? tick?
_Suggestion for a concept for the behaviour of animals in swarms. _
Sample concept for Wolf-Pack
Variables Dehydration Hunger Hideoutposition
States Hide at Day Come out at dawn Finding water source for drinking Finding a delicous chicken Hunting chicken Eating Chicken: On Success Breeding
Sample concept for Cow and Sheep
Variables Dehydration Hunger
States Finding water source for drinking Finding and eat grass Move away from danger Breeding