Integrated Dynamics

Integrated Dynamics

63M Downloads

Crash when trying to display computed item damage ratio

shabble opened this issue ยท 1 comments

commented

Crash with attached crashlog.

java.lang.ClassCastException: org.cyclops.integrateddynamics.core.evaluate.variable.ValueTypeCategoryNumber
cannot be cast to org.cyclops.integrateddynamics.api.evaluate.variable.IValueTypeNumber

at org.cyclops.integrateddynamics.core.evaluate.OperatorBuilders$7.getConditionalOutputType(OperatorBuilders.java:97)

Context is approximately:

i = materialised item (emerald helmet with ~90% durability)
d1 = maxdamage(i)
d2 = damage(i)

dn1 = castIntToNum(d1)
dn2 = castIntToNum(d2)

dratio = div(d1, d2)

placing dratio in display panel caused the crash.

More details can be provided if useful.

Versions:

  • IntegratedDynamics-1.10.2-0.6.7.jar
  • IntegratedTunnels-1.10.2-1.1.0.jar
  • CyclopsCore-1.9.4-0.9.1.jar

crashlog.txt

commented

@shabble Casting to numbers will be removed in the next update. It is not required anymore, so this will simplify your logic slightly.