Fixed a bug with large numbers and chain calculations (Thanks to an anonymous wikia user)