From ccb44d0c6e9fd9e3c28bad2ce87091eb5afdc266 Mon Sep 17 00:00:00 2001 From: qndel Date: Sat, 28 Mar 2020 04:57:05 +0100 Subject: [PATCH] [hellfire] S_BBuyEnter bin exact --- Source/stores.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Source/stores.cpp b/Source/stores.cpp index 8e06f02d5..ece68445e 100644 --- a/Source/stores.cpp +++ b/Source/stores.cpp @@ -2408,11 +2408,19 @@ void S_BBuyEnter() stextshold = STORE_BBOY; stextvhold = stextsval; stextlhold = 10; +#ifdef HELLFIRE + if (plr[myplr]._pGold < boyitem._iIvalue - (boyitem._iIvalue >> 2)) { +#else if (plr[myplr]._pGold < boyitem._iIvalue + (boyitem._iIvalue >> 1)) { +#endif StartStore(STORE_NOMONEY); } else { plr[myplr].HoldItem = boyitem; +#ifdef HELLFIRE + plr[myplr].HoldItem._iIvalue -= plr[myplr].HoldItem._iIvalue >> 2; +#else plr[myplr].HoldItem._iIvalue += plr[myplr].HoldItem._iIvalue >> 1; +#endif SetCursor_(plr[myplr].HoldItem._iCurs + CURSOR_FIRSTITEM); done = FALSE; for (i = 0; i < 40 && !done; i++) {