Jump to content

Recommended Posts

Posted

So im am attempting to put my friend as a mob into the game, and I dont know which kind of entity i should extend. Ideas? Also, what syntax do i use to edit strength, speed, and life of mobs? I have other mobs i want to make faster and stronger, stuff like that. Thanks for help in advance!

Posted

1st of all, for what type to extend, that depends, do you want it to be peaceful? Do you want it to be aggressive? If peaceful: The EntityCreature class. If aggressive: The EntityMob class. 2nd of all, for strength, speed, life, etc, you use some code like this:

protected void applyEntityAttributes()
    {
        super.applyEntityAttributes();
        this.getEntityAttribute(SharedMonsterAttributes.maxHealth).setBaseValue(20.0D);
        this.getEntityAttribute(SharedMonsterAttributes.followRange).setBaseValue(40.0D);
        this.getEntityAttribute(SharedMonsterAttributes.movementSpeed).setBaseValue(0.23000000417232513D);
        this.getEntityAttribute(SharedMonsterAttributes.attackDamage).setBaseValue(5.0D);
    }

You could just paste that right in you mob class and change the values how you like. :)

As for making mobs talk I don't know how other than recording your friend talking and incorporate the sound files from that... I'm not sure. Hope this helps. :)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.