Commit Graph
9 Commits
Author SHA1 Message Date
MacweeseandMacweese 4891962789 projectileid: mage arena 2 (#2831)
Addition of MA2 NPCs AoEs and projectile.

Co-authored-by: Macweese <50101641+Macweese@users.noreply.github.com;macweese@pm.me>
2020-10-20 16:53:00 +01:00
Macweese f3a4ef3518 Update ImageCapture.java 2020-09-07 18:47:25 +02:00
Macweese 9b7a2e5cfd Sort coordinates
Added Math.min() & Math.max() when passing point coordinates.

This makes it easier to add new locations without having to worry about entering the specific coordinates to the respective parameter.
I.e. no need to follow the previously addressed convention.

...Just in case.

• Adjusted a few locations tiny bit.
• Removed Wilderness Obelisk 27 Portal as I felt Wilderness GWD is so close and is a more descriptive location.
2020-09-07 15:03:47 +02:00
Macweese af733b76b1 import worldtype maybe
ape
2020-09-06 19:49:15 +02:00
Macweese 5166e9921e PlayerManager: High risk world mechanics
Checkstyle
2020-09-06 19:39:30 +02:00
Macweese f93d7e8847 PlayerManager: High risk world mechanics
Update PlayerManager to work with the latest changes made to high risk worlds.

Protect item prayer is completely disabled on high risk worlds.

Also changed the ternary operator to only apply if the prayer level is less than 25, since players can use the prayer if they are 25 prayer.
2020-09-06 19:30:46 +02:00
Macweese 65d2f45090 WorldLocation: Fields hierarchy
After some testing I found that a niche issue arises from the combination of the alphabetical sorting and the for loop. This aims to band-aid the issue as best possible until proper rework is done.

Renamed fields

Appended main areas (BB) which house other locations with `_ZONE` .

Example
Old → `HOSIDIUS("Hosidius", new Location(1737, 3627, 1789, 3582), 0),`
New → `HOSIDIUS_ZONE("Hosidius", new Location(1737, 3627, 1789, 3582), 0),`

Reason for this is to solve a problem with the `for loop` responsible for iterating over all locations to find which one the player is located in.
Since they are sorted alphabetically, `HOSIDIUS` comes before `HOSIDIUS_BANK` or any other location prefixed with "hosidius".
Disregarding if  `worldArea ∈ BB`.

So, coincidentally, appending BB areas with `_ZONE` is just a lucky "solution" as a result of the alphabetical sorting to push the area down in the hierarchy.

To be clear; This is a hack, not a proper solution.
Ideally, in a perfect world the entire thing would be replaced by a proper R-Tree or other spatial access method.
However, for now, this is as good as it gets seeing as it'd be a pretty big task.
2020-09-05 10:54:21 +02:00
Macweese 49fa4c7f08 WorldLocation: Major expansion
Added over 500 new locations.
Some locations were merged together, or split further into finer segments.
Removed few locations.

Spelling corrections

Renamed and organised fields.
Renamed few field display labels to give a more intuitive description of the intended world point.

Limited margin of "distance to area" to 128 squares(region length*2) to prevent mislabeling areas. Particularly in instances.

Fixed error which caused each world area to be placed on wrong coordinates along y-axis.

Added Math.abs() to get absolute value when calculating polygon dimensions from coordinates.
2020-09-03 21:00:30 +02:00
Macweese c1b0ca4ffd agility shortcuts: fix north Arceuus Dense essence mine shortcut 2019-05-07 10:53:54 -04:00