mirror of
https://github.com/gooba42/adventureland.git
synced 2026-10-14 10:33:47 -05:00
Merge pull request #211 from earthiverse/monster-dimensions
fix monster dimensions
This commit is contained in:
+6
-1
@@ -11260,6 +11260,12 @@ function new_monster(instance, map_def, args) {
|
|||||||
if (G.dimensions[name]) {
|
if (G.dimensions[name]) {
|
||||||
monster.width = G.dimensions[name][0];
|
monster.width = G.dimensions[name][0];
|
||||||
monster.height = G.dimensions[name][1];
|
monster.height = G.dimensions[name][1];
|
||||||
|
} else {
|
||||||
|
monster.width = monster.height = 24;
|
||||||
|
}
|
||||||
|
if (G.monsters[monster.type].size) {
|
||||||
|
monster.width = Math.round(monster.width * G.monsters[monster.type].size);
|
||||||
|
monster.height = Math.round(monster.height * G.monsters[monster.type].size);
|
||||||
}
|
}
|
||||||
set_base(monster);
|
set_base(monster);
|
||||||
|
|
||||||
@@ -11358,7 +11364,6 @@ function new_monster(instance, map_def, args) {
|
|||||||
if (mode.range_test) {
|
if (mode.range_test) {
|
||||||
monster.range = 2000;
|
monster.range = 2000;
|
||||||
}
|
}
|
||||||
monster.width = monster.height = 24;
|
|
||||||
if (args.temp) {
|
if (args.temp) {
|
||||||
monster.temp = 1;
|
monster.temp = 1;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user