I'll check your code after work. Shouldn't be a problem with of click but it might be something I overlooked
Found the problem your using obj for an array you need to specify
Obj[0].Coords
-
Paradoxs
- Posts: 294
- Joined: Tue Aug 25, 2015 7:16 am
Release 1.0
Prime Release 1.0
https://github.com/TimothyCates/amber/releases
This release is more of a merge + preparing for new functions release
Prime now comes in a flavor that doesnt pre-pack the API
Changes
Prime-API Release 1.0
https://github.com/TimothyCates/PrimeAPI/releases
Api is switching to semantic versioning starting with this release, it marks the first release using the build system I developed in c++ for organizational purposes.
API now has release versions posted to github
This release was pushed in part of the prime client merges so not everything is completely ready, these functions are marked with -Unused
Fixes
Below is a list of goals for next version
To Do
https://github.com/TimothyCates/amber/releases
This release is more of a merge + preparing for new functions release
Prime now comes in a flavor that doesnt pre-pack the API
Changes
- You can now name objects with Control + Click
Take when pressed on a stockpile takes all if the Amount field is empty
Prime-res is now separate from amber-res to fix merge conflicts
Prime-API Release 1.0
https://github.com/TimothyCates/PrimeAPI/releases
Api is switching to semantic versioning starting with this release, it marks the first release using the build system I developed in c++ for organizational purposes.
API now has release versions posted to github
This release was pushed in part of the prime client merges so not everything is completely ready, these functions are marked with -Unused
Fixes
- Fixed a condition Error in getItem breaking under rare conditions
closeWindow and closeFlower now send correct closing messages instead of hiding the objects to fix rare odd errors
All wait and sleep functions listen to the stop button to prevent run-away threads
- Tile Object - Unsed
Craft Mode Object
Key Object -Unused
Sort Object -Unused
Added Inventory.Equipment to Inventory Object -Unused (Works for getItems() or getitem but does not interface anywhere else yet)
- getTile(X, Y)
- Returns an integer representation of the tile at coords X, Y
- returns true or false on whether the stop button has been pressed
- returns true if item in hand is found after 10 seconds or Timeout in milliseconds otherwise returns false
- returns true if hourglass percentage is found and at least 1% after 10 seconds or Timeout in milliseconds otherwise returns false
- Attempts to craft ItemName, take CraftMode.All or CraftMode.One. returns true if crafted, returns false otherwise
Below is a list of goals for next version
To Do
- JSDocs (about half way complete, work really cuts into this)
Finish equipment related functions
Add isRidge to tile object
Incorporate Tile Object into get Tile
getData and SendData for sqlLite being integrated into client
SwitchCharater function
Inventory Size Function
Free Inventory Slots function
Sort Map Objects
Sort Inventory Objects
Add Quality to Item Object
Drop All Function
Close To Function
get distance Function
Include larger array of examples
Redo PrimeAPI GUI
-
ae_maderero
- Posts: 7
- Joined: Fri Jan 13, 2017 4:48 pm
Re: Prime - Amber Tweaks and Scripting API
That's not the problem, I modified the function and it returned 1 object. The problem is getHighlightedMapObjects returns objects with Coord2d, while getCoords returns Coord.Paradoxs wrote:I'll check your code after work. Shouldn't be a problem with of click but it might be something I overlooked
Found the problem your using obj for an array you need to specify
Obj[0].Coords
-
Paradoxs
- Posts: 294
- Joined: Tue Aug 25, 2015 7:16 am
Re: Prime - Amber Tweaks and Scripting API
Let me take a look. Because last I checked I modified them all to pump into a map object that I custom madeae_maderero wrote:That's not the problem, I modified the function and it returned 1 object. The problem is getHighlightedMapObjects returns objects with Coord2d, while getCoords returns Coord.Paradoxs wrote:I'll check your code after work. Shouldn't be a problem with of click but it might be something I overlooked
Found the problem your using obj for an array you need to specify
Obj[0].Coords
-
Paradoxs
- Posts: 294
- Joined: Tue Aug 25, 2015 7:16 am
Re: Prime - Amber Tweaks and Scripting API
Make sure your using the latest version because IV tested and succeeded in usingae_maderero wrote:That's not the problem, I modified the function and it returned 1 object. The problem is getHighlightedMapObjects returns objects with Coord2d, while getCoords returns Coord.Paradoxs wrote:I'll check your code after work. Shouldn't be a problem with of click but it might be something I overlooked
Found the problem your using obj for an array you need to specify
Obj[0].Coords
Code: Select all
var boat = getHighlightedMapObjects()[0];
pfClick(boat);
-
ae_maderero
- Posts: 7
- Joined: Fri Jan 13, 2017 4:48 pm
Re: Prime - Amber Tweaks and Scripting API
That works, when it doesnt work is when you add a value, like doing coord.x +10.
-
Paradoxs
- Posts: 294
- Joined: Tue Aug 25, 2015 7:16 am
Re: Prime - Amber Tweaks and Scripting API
ae_maderero wrote:That works, when it doesnt work is when you add a value, like doing coord.x +10.
I will look at it and see if I can figure out what's going on.
-
ae_maderero
- Posts: 7
- Joined: Fri Jan 13, 2017 4:48 pm
Re: Prime - Amber Tweaks and Scripting API
Ty! Btw, a function to check if u are lifting something would be great. I made one, but its dirty code involving movement speed.Paradoxs wrote:ae_maderero wrote:That works, when it doesnt work is when you add a value, like doing coord.x +10.
I will look at it and see if I can figure out what's going on.
Also, dont use "typeof X != XXX", since you are going to work with Java classes. Use .class.getSimpleName()
-
LostJustice
- Posts: 691
- Joined: Sun Mar 25, 2012 3:57 am
Re: Prime - Amber Tweaks and Scripting API
I asked him about this as well and I can confirm that he is working on this. Just a bit of difficulties right now in allowing for this but will come eventually.ae_maderero wrote:Ty! Btw, a function to check if u are lifting something would be great. I made one, but its dirty code involving movement speed.Paradoxs wrote:ae_maderero wrote:That works, when it doesnt work is when you add a value, like doing coord.x +10.
I will look at it and see if I can figure out what's going on.
Also, dont use "typeof X != XXX", since you are going to work with Java classes. Use .class.getSimpleName()

-
ae_maderero
- Posts: 7
- Joined: Fri Jan 13, 2017 4:48 pm
Re: Prime - Amber Tweaks and Scripting API
If any of u guys got an example of what Im trying to archieve, maybe we find what's wrong.
I want to auto unload what I have lifted. I get an signpost as reference, and try to rightclick at signpost.Coords + X, a tile I left free.
I want to auto unload what I have lifted. I get an signpost as reference, and try to rightclick at signpost.Coords + X, a tile I left free.