Open-source multiplayer game server compatible with the RuneScape client
https://www.openrs2.org/
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
462 B
18 lines
462 B
4 years ago
|
package org.openrs2.deob.bytecode.analysis
|
||
4 years ago
|
|
||
4 years ago
|
public enum class IntBranchResult {
|
||
4 years ago
|
ALWAYS_TAKEN, NEVER_TAKEN, UNKNOWN;
|
||
|
|
||
4 years ago
|
public companion object {
|
||
|
public fun fromTakenNotTaken(taken: Int, notTaken: Int): IntBranchResult {
|
||
4 years ago
|
require(taken != 0 || notTaken != 0)
|
||
|
|
||
|
return when {
|
||
|
taken == 0 -> NEVER_TAKEN
|
||
|
notTaken == 0 -> ALWAYS_TAKEN
|
||
|
else -> UNKNOWN
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
}
|