From 19e016ae782cec21526aa15e4ebf06543113873a Mon Sep 17 00:00:00 2001 From: Luther Wen Xu Date: Thu, 28 Nov 2019 12:11:06 +0800 Subject: [PATCH] modules/gacha: Fix implementation of random --- modules/gacha/rand.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/gacha/rand.go b/modules/gacha/rand.go index 6ffa2b0..2e82055 100644 --- a/modules/gacha/rand.go +++ b/modules/gacha/rand.go @@ -16,7 +16,7 @@ func (cryptoSource) Int63() int64 { if err != nil { panic(err) } - return int64(value ^ uint64(1<<63)) + return int64(value & ^uint64(1<<63)) } func (cryptoSource) Seed(seed int64) {}