From 2e13ef34f86930ed9b15aa5a0b98c3927523a486 Mon Sep 17 00:00:00 2001 From: onezplpl Date: Sat, 20 Jul 2024 17:09:19 -0400 Subject: [PATCH] add a stack limit --- control.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/control.c b/control.c index 290a32e..6d79828 100644 --- a/control.c +++ b/control.c @@ -169,7 +169,7 @@ void control_lclick(double cx, double cy, vec3 pos, struct item *inv) { inv[i].id = cube; inv[i].count = 0; } - if (inv[i].id == cube) { + if (inv[i].id == cube && inv[i].count < 64) { inv[i].count++; break; }