Single Use Potion Problem

Post here about all aspects of D2 mod making whether it's information, problems or whatever. Please specify whether your post is relating to Classic D2 or the Expansion.

Moderator: Nizari

Post Reply
User avatar
pepa999
Posts: 57
Joined: Mon Oct 20, 2008 7:10 pm
Czech Republic

Single Use Potion Problem

Post by pepa999 » Wed May 15, 2019 11:34 pm

Hi i followed this tutorial to create single use potion.

kb/viewarticle?a=439

It works, but problem is, that i want to add passive hp regeneration "stat('maxhp'.accr)/(25*120)", so full hp in 120 seconds just like original mana regeneration.

But the game here weirdly doesnt work with 1/256ths piece of hit poitns however it is still per one frame. So minimum regeneration is 25 hitpoints per seconds. Less will be truncated to zero.

Please help, how can i solve this?

User avatar
huohuowu2
Junior Member
Paladin
Posts: 144
Joined: Sat Feb 28, 2015 4:20 am
China

Re: Single Use Potion Problem

Post by huohuowu2 » Thu May 16, 2019 1:52 am

pspell=9
stat=choice one in state.txt
len=3000
stat1=hpregen
calc1=stat('maxhp'.accr)/3000

User avatar
pepa999
Posts: 57
Joined: Mon Oct 20, 2008 7:10 pm
Czech Republic

Re: Single Use Potion Problem

Post by pepa999 » Thu May 16, 2019 11:15 pm

Thank you, but i would like permanent hp regeneration just like mana regeneration is permanent and is saved through games.

User avatar
huohuowu2
Junior Member
Paladin
Posts: 144
Joined: Sat Feb 28, 2015 4:20 am
China

Re: Single Use Potion Problem

Post by huohuowu2 » Fri May 17, 2019 3:13 am

type=elix
pspell=4
stat1=hpregen
calc1=stat('maxhp'.accr)/3000

User avatar
huohuowu2
Junior Member
Paladin
Posts: 144
Joined: Sat Feb 28, 2015 4:20 am
China

Re: Single Use Potion Problem

Post by huohuowu2 » Fri May 17, 2019 3:17 am

you also need change hpregen in ItemStatCost.txt,like strength,set saved and CSVbits.

Post Reply

Return to “General Mod Making”