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.

Featured Replies

  • Author

alright, the wolf is levelling up and all that stuff, now im finally using the WolfExtendedClass for something, for the sake of testing im making it evolve into an ocelot when it reaches it's max level, so more errors were bound to come.

repo: https://github.com/jokekid/BattleCreatures/tree/GetPetsWithinRange

 

im getting a null pointer exception right here:

https://github.com/jokekid/BattleCreatures/blob/GetPetsWithinRange/src/main/java/com/jokekid/battlecreatures/extEntity/ExtendedTameable.java#L83

 

you guys are probably smacking your heads against the wall cuz i made some stupid mistake, but sorry, im  not seeing it :/

  • Author

player was null for a stupid mistake, instead of entity.getOwner(), i needed THIS.entity...

so yeah, but now the ocelot won't spawn...

 

EDIT: everything's working properly now,all i had to do was give the new entity it's coords, which is ez pz :D

i also had to add a check to make sure a tameable entity actually had extended properties before trying to give it experience (ocelots dont have extended properties yet)

 

so yes, i finally got this thing working fully, thanks a bunch diesieben07 you are my hero <3

  • Author

EDIT: everything's working properly now,all i had to do was give the new entity it's coords, which is ez pz :D

i also had to add a check to make sure a tameable entity actually had extended properties before trying to give it experience (ocelots dont have extended properties yet)

 

so yes, i finally got this thing working fully, thanks a bunch diesieben07 you are my hero <3

 

for testing purposes i made the wolf evolve into an ocelot.

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...

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.