Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

ElkMan3

Members
  • Joined

  • Last visited

Everything posted by ElkMan3

  1. Hello, i am working on a mob that can have different 'personalities'. with each personality, the ai will be slightly different shy would run from the player aggressive would attack etc I set this personality as a synced value, on entity spawn. the problem Is, that the personality is set after the ai is. so is there a way to set the ai goals after the entity has been created?
  2. I have a custom entity(i use MCreator to make templates, and i edit the code myself) im making a mob that can have different personalities, and that will change the behavior. how I'm setting the personality is through an nbt tag. i initially set this tag on the trigger that MCreator provides, onEntitySpawn, but this would trigger after the entities goals have already been set, so I changed it so that is called before the goals have been set. The problem is, that It is not working. Is NBT data available this early in the definition? this is the relevant code: (the null check is so that the personality is not changed if it already has been set, and GnomeOnInitialEntitySpawnProcedure() just calls a few things, including the personality assignment ) public String getPersonality() { return this.getPersistentData().getString("Personality"); } @Override protected void registerGoals() { String personality = this.getPersonality(); if(personality == null || personality.isEmpty()) { GnomeOnInitialEntitySpawnProcedure.execute(this); }

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.