projects
/
gbrg
/
.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d4a35b6
)
mapgen: reduced amount of spawned actors
author
Lukas Krickl
<lukas@krickl.dev>
Tue, 5 Aug 2025 19:54:04 +0000
(21:54 +0200)
committer
Lukas Krickl
<lukas@krickl.dev>
Tue, 5 Aug 2025 19:54:04 +0000
(21:54 +0200)
src/defs.s
patch
|
blob
|
history
src/mapgen.s
patch
|
blob
|
history
diff --git
a/src/defs.s
b/src/defs.s
index 7d5faddb13d260cc63aeeb429cf56192dc8022f1..ce128fd1f0742270c64846a8c11253790a2451ab 100644
(file)
--- a/
src/defs.s
+++ b/
src/defs.s
@@
-21,8
+21,8
@@
#define NULL 0
#define UNITS_MAX 20
-#define UNITS_SPAWN_MIN
4
-#define UNITS_SPAWN_MASK
7
+#define UNITS_SPAWN_MIN
2
+#define UNITS_SPAWN_MASK
3
#define STACK_BEGIN 0xDFFF
diff --git
a/src/mapgen.s
b/src/mapgen.s
index 3ee5a31a3f33fd3aaac8f8da595e87736dfc49d9..127dc81722d84b47ca03fb06c1b72ec9f2ce5854 100644
(file)
--- a/
src/mapgen.s
+++ b/
src/mapgen.s
@@
-439,7
+439,7
@@
mapgen_place_actors:
ld b, UNITS_MAX - 1
push hl
call rand
- and a, UNITS_SPAWN_MASK
+ and a, UNITS_SPAWN_MASK
add a, UNITS_SPAWN_MIN
ld b, a
; b = units to spawn, at least 4 but might be more