Jump to content

camera.getZ and ItemDefinition.forId broken?


Recommended Posts

Posted (edited)

Is the camera Z meant to be the zoom or just the Z axis of the camera? If no, how would I be able to tell when it hit max zoomout? I know there's a call for checking if the scale is defaulted, but I want to see the scale value itself. Doesn't seem to be a getter for it either :(

Secondly, ItemDefinition.forId(1993) returns null, is it broken? I recall it working properly when I last tried it, don't know why it doesn't work now...

EDIT: Sometime's it's broken, sometime's it works. How can I make it work 100%? 

I just opened my bank, closed it and then re-ran the test script. Magically,  it started working again... 

1993 = Jug of wine.

Edited by Satire
Posted (edited)

copied from the api:

Quote

Gets the definition for an item based on it's id. Note: This method might return null because the item hasn't been loaded by the client yet!

 

To make sure your camera is at the max distance i would open the settings and use configs to change the camera to its max position.

You can get the values by printing the getters of z, x and y.

Edited by zwaffel
Posted (edited)
On 6/7/2019 at 8:04 AM, Chris said:

i use ItemDefinition for worn gear in my dragon aio. it should be working 100%

How does it operate? It nulls out on me during initialization of my class constructor. Sometimes it returns null, sometimes it doesn't. Is there a way I can force reload the ItemDefinition list? This is really a core part of my script...  Or will I have to hardcode the ID's I use... 

EDIT: dw, I just hardcoded it. 0 issues now, I run too many bots for me to rely on .forID, it just isn't reliable whatsoever.

On 6/9/2019 at 1:49 AM, zwaffel said:

copied from the api:

 

To make sure your camera is at the max distance i would open the settings and use configs to change the camera to its max position.

You can get the values by printing the getters of z, x and y.

the Z getter is not actually the camera's scale. The actual Z for the scale doesn't "exist". Wish I knew why it wasn't public lmao 

Edited by Satire

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...