mirror of
https://github.com/MarioSpore/Grinch-AP.git
synced 2025-10-21 20:21:32 -06:00
RoR2: code cleanup and styling consistency (#833)
* build locations dict dynamically from the TotalLocations option. Minor styling cleanup * Minor items styling cleanup. remove unused event items * minor options cleanup. clarify preset toggle slightly better * make items.py more readable. add chaos weights dict to use as reference point for generation * small rules styling and consistency cleanup * create less regions and other init cleanup * move region creation to less function calls and move revivals calculation * typing * use enum instead of hardcoded ints. fix bug i introduced * better typing
This commit is contained in:
@@ -1,19 +1,13 @@
|
||||
from typing import Dict
|
||||
from BaseClasses import Location
|
||||
import typing
|
||||
from .Options import TotalLocations
|
||||
|
||||
|
||||
class RiskOfRainLocation(Location):
|
||||
game: str = "Risk of Rain 2"
|
||||
|
||||
# 37000 - 38000
|
||||
base_location_table = {
|
||||
"Victory": None,
|
||||
|
||||
}
|
||||
# 37006 - 37506
|
||||
item_pickups = {
|
||||
f"ItemPickup{i}": 37005+i for i in range(1, 501)
|
||||
item_pickups: Dict[str, int] = {
|
||||
f"ItemPickup{i+1}": 37000+i for i in range(TotalLocations.range_end)
|
||||
}
|
||||
|
||||
location_table = {**base_location_table, **item_pickups}
|
||||
|
||||
lookup_id_to_name: typing.Dict[int, str] = {id: name for name, id in location_table.items()}
|
||||
|
||||
Reference in New Issue
Block a user