Giter Club home page Giter Club logo

godicepool's People

Contributors

ramainen avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Forkers

since1968

godicepool's Issues

Rending bug

Hi, we previously talked on reddit about your wonderful web app. Thanks again. I was glancing through the code and I might have spotted a bug in the Rending-related code.

attacks.go L44-L49 has...

	if weapon.Rending > 0 {
		if attackCritCount > 0 {
			attackCritCount = attackCritCount + attackSuccessCount
			attackSuccessCount = 0
		}
	}

The Rending code seems to be "if any crit hits are retained, transform all normal hits into crit hits", but the Rending rule says "if you retain any critical hits you can retain one normal hit as a critical hit"

So maybe the code should be...

	if weapon.Rending > 0 {
		if attackCritCount > 0 && attackSuccessCount > 0 {
			attackCritCount++;
			attackSuccessCount--;
		}
	}

defensive strategy of cancelling crit and norm hits should depend crit/norm damage ratio

Starting at attacks.go L95, the logic for defense dice cancelling attack dice does not depend on the crit/norm damage ratio. If crit damage is more than double norm damage, then you highly prioritize cancelling crits. If crit damage is less than norm damage (happens on weapons with MWx), then you highly prioritize cancelling norms. And you want logic to handle the in-between case.

You can see my KT21Calculator KT21CalcEngine.calcDamage function for example logic.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.