Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[hellfire] missiles_berserk bin exact #1702

Merged
merged 4 commits into from
Sep 20, 2019

Conversation

qndel
Copy link
Member

@qndel qndel commented Sep 20, 2019

No description provided.

Source/missiles.cpp Outdated Show resolved Hide resolved
Source/missiles.cpp Outdated Show resolved Hide resolved
qndel and others added 2 commits September 20, 2019 11:05
Co-Authored-By: Anders Jenbo <anders@jenbo.dk>
Co-Authored-By: Anders Jenbo <anders@jenbo.dk>
@AJenbo AJenbo merged commit ed4f056 into diasurgical:hellfire Sep 20, 2019
@AJenbo AJenbo deleted the missiles_berserk branch September 20, 2019 09:06
j = 6;
double slvl = (double)GetSpellLevel(id, SPL_BERSERK);
monster[dm]._mFlags |= MFLAG_UNUSED | MFLAG_GOLEM; //is this ok?
monster[dm].mMinDamage = (__int64)(((double)(random(145, 10) + 20) * 0.01 - -1.0) * (double)monster[dm].mMinDamage + slvl);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm to tired to test. But couldn't this be written as follows?
((double)(random(145, 10) + 20) / 100 + 1) * (double)monster[dm].mMinDamage + slvl;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants