Fix totally busted getScenery

This commit is contained in:
Player Name 2026-07-30 14:25:33 +02:00
parent a3323c5778
commit 883eac2015
2 changed files with 5 additions and 6 deletions

View file

@ -370,7 +370,7 @@ public final class TzhaarFightPitsPlugin extends ActivityPlugin {
}
int size = (LOBBY_PLAYERS.size() + WAR_PLAYERS.size()) - 1;
if (!WAR_PLAYERS.isEmpty()) {
setVarp(WAR_PLAYERS.get(0), 560, size);
setVarp(WAR_PLAYERS.get(0), 560, size);
}
for (Iterator<Player> it = LOBBY_PLAYERS.iterator(); it.hasNext();) {
Player p = it.next();
@ -382,7 +382,7 @@ public final class TzhaarFightPitsPlugin extends ActivityPlugin {
}
p.getSkullManager().setSkullCheckDisabled(true);
p.getSkullManager().setWilderness(true);
setVarp(p, 560, size);
setVarp(p, 560, size);
p.getProperties().setTeleportLocation(getZoneDestination());
p.getInteraction().set(Option._P_ATTACK);
tokkulAmount += p.getProperties().getCurrentCombatLevel();
@ -464,7 +464,7 @@ public final class TzhaarFightPitsPlugin extends ActivityPlugin {
*/
public static void sendPlayersRemaining(int value) {
for (Player p : WAR_PLAYERS) {
setVarp(p, 560, value);
setVarp(p, 560, value);
}
}

View file

@ -1078,10 +1078,9 @@ fun findNPC(id: Int): NPC? {
* @param x the X coordinate to use
* @param y the Y coordinate to use
* @param z the Z coordinate to use
* @param type the scenery type, -1 if any
*/
fun getScenery(x: Int, y: Int, z: Int, type: Int = -1): Scenery? {
return RegionManager.getObject(z, x, y, type, -1)
fun getScenery(x: Int, y: Int, z: Int): Scenery? {
return RegionManager.getObject(z, x, y)
}
/**