Fix formatting throughout various plugins.

This commit is contained in:
Major-
2014-08-03 18:13:44 +01:00
parent 6349bc5892
commit 08cb196143
7 changed files with 38 additions and 242 deletions
+5 -3
View File
@@ -2,6 +2,8 @@ require 'java'
java_import 'org.apollo.game.model.entity.Player'
# Todo make 0 the default height
# A map of coordinates (as an array) to areas.
AREAS = []
@@ -33,12 +35,12 @@ end
# Creates a new area and registers it with the supplied coordinates.
def area(hash)
raise "Hash must contain a name, coordinates, and actions pair." unless hash.has_key?(:name) && hash.has_key?(:coordinates) && hash.has_key?(:actions)
raise 'Hash must contain a name, coordinates, and actions pair.' unless hash.has_key?(:name) && hash.has_key?(:coordinates) && hash.has_key?(:actions)
name = hash[:name]; coordinates = hash[:coordinates]; actions = hash[:actions]
AREAS << Area.new(name, coordinates, actions.is_a?(Symbol) ? [actions] : actions)
end
# Coordinates refer to the bottom-left position (min_x, min_y) and the top-right position (max_x, max_y), followed by the height.
# Coordinates refer to the bottom-left position (min_x, min_y) and the top-right position (max_x, max_y), followed by the height (optional).
area :name => :wilderness, :coordinates => [ 2944, 3520, 3391, 3967, 0 ], :actions => [ :pvp, :multicombat, :wilderness ]
area :name => :duel_arena, :coordinates => [ 3327, 3200, 3392, 3286, 0 ], :actions => :pvp
area :name => :duel_arena, :coordinates => [ 3327, 3200, 3392, 3286 ], :actions => :pvp