Merge pull request #53 from noelleleigh/Python-3.12

Support Python 3.12
master
Nate Smith 2024-04-04 15:14:58 -04:00 committed by GitHub
commit ccc08316fe
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -164,7 +164,7 @@ class Plant:
def rarity_check(self): def rarity_check(self):
# Generate plant rarity # Generate plant rarity
CONST_RARITY_MAX = 256.0 CONST_RARITY_MAX = 256.0
rare_seed = random.randint(1,CONST_RARITY_MAX) rare_seed = random.randint(1,int(CONST_RARITY_MAX))
common_range = round((2.0/3)*CONST_RARITY_MAX) common_range = round((2.0/3)*CONST_RARITY_MAX)
uncommon_range = round((2.0/3)*(CONST_RARITY_MAX-common_range)) uncommon_range = round((2.0/3)*(CONST_RARITY_MAX-common_range))
rare_range = round((2.0/3)*(CONST_RARITY_MAX-common_range-uncommon_range)) rare_range = round((2.0/3)*(CONST_RARITY_MAX-common_range-uncommon_range))