MCPcopy Index your code
hub / github.com/codecombat/codecombat / expForLevel

Method expForLevel

app/models/User.js:391–393  ·  view source on GitHub ↗
(level)

Source from the content-addressed store, hash-verified

389
390 // x = b * e^((y-1)/a) - c
391 static expForLevel (level) {
392 if (level > 1) { return Math.ceil((Math.exp((level - 1) / a) * b) - c) } else { return 0 }
393 }
394
395 static tierFromLevel (level) {
396 // TODO: math

Callers 4

User.spec.jsFile · 0.80
calculateDataMethod · 0.80
updateXPBarsMethod · 0.80
updateXPBarsMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected