SoE: WebWorld theme and fix long standing bug (#397)
This commit is contained in:
parent
4dd0a75914
commit
5392b32d5c
|
@ -1,4 +1,4 @@
|
||||||
from ..AutoWorld import World
|
from ..AutoWorld import World, WebWorld
|
||||||
from ..generic.Rules import set_rule
|
from ..generic.Rules import set_rule
|
||||||
from BaseClasses import Region, Location, Entrance, Item, RegionType
|
from BaseClasses import Region, Location, Entrance, Item, RegionType
|
||||||
from Utils import output_path
|
from Utils import output_path
|
||||||
|
@ -7,7 +7,6 @@ import os
|
||||||
import os.path
|
import os.path
|
||||||
import threading
|
import threading
|
||||||
import itertools
|
import itertools
|
||||||
import time
|
|
||||||
|
|
||||||
try:
|
try:
|
||||||
import pyevermizer # from package
|
import pyevermizer # from package
|
||||||
|
@ -133,6 +132,10 @@ def _get_item_grouping() -> typing.Dict[str, typing.Set[str]]:
|
||||||
return groups
|
return groups
|
||||||
|
|
||||||
|
|
||||||
|
class SoEWebWorld(WebWorld):
|
||||||
|
theme = 'jungle'
|
||||||
|
|
||||||
|
|
||||||
class SoEWorld(World):
|
class SoEWorld(World):
|
||||||
"""
|
"""
|
||||||
Secret of Evermore is a SNES action RPG. You learn alchemy spells, fight bosses and gather rocket parts to visit a
|
Secret of Evermore is a SNES action RPG. You learn alchemy spells, fight bosses and gather rocket parts to visit a
|
||||||
|
@ -140,14 +143,17 @@ class SoEWorld(World):
|
||||||
"""
|
"""
|
||||||
game: str = "Secret of Evermore"
|
game: str = "Secret of Evermore"
|
||||||
options = soe_options
|
options = soe_options
|
||||||
topology_present: bool = False
|
topology_present = False
|
||||||
remote_items: bool = False
|
remote_items = False
|
||||||
data_version = 2
|
data_version = 2
|
||||||
|
web = SoEWebWorld()
|
||||||
|
|
||||||
item_name_to_id, item_id_to_raw = _get_item_mapping()
|
item_name_to_id, item_id_to_raw = _get_item_mapping()
|
||||||
location_name_to_id, location_id_to_raw = _get_location_mapping()
|
location_name_to_id, location_id_to_raw = _get_location_mapping()
|
||||||
item_name_groups = _get_item_grouping()
|
item_name_groups = _get_item_grouping()
|
||||||
|
|
||||||
|
trap_types = [name[12:] for name in options if name.startswith('trap_chance_')]
|
||||||
|
|
||||||
evermizer_seed: int
|
evermizer_seed: int
|
||||||
connect_name: str
|
connect_name: str
|
||||||
|
|
||||||
|
@ -189,9 +195,8 @@ class SoEWorld(World):
|
||||||
trap_count = self.world.trap_count[self.player].value
|
trap_count = self.world.trap_count[self.player].value
|
||||||
trap_chances = {}
|
trap_chances = {}
|
||||||
trap_names = {}
|
trap_names = {}
|
||||||
fool = 1648731600 <= time.time() <= 1648900800
|
|
||||||
if trap_count > 0:
|
if trap_count > 0:
|
||||||
for trap_type in ("quake", "poison", "confound", "hud", "ohko"):
|
for trap_type in self.trap_types:
|
||||||
trap_option = getattr(self.world, f'trap_chance_{trap_type}')[self.player]
|
trap_option = getattr(self.world, f'trap_chance_{trap_type}')[self.player]
|
||||||
trap_chances[trap_type] = trap_option.value
|
trap_chances[trap_type] = trap_option.value
|
||||||
trap_names[trap_type] = trap_option.item_name
|
trap_names[trap_type] = trap_option.item_name
|
||||||
|
@ -200,11 +205,6 @@ class SoEWorld(World):
|
||||||
for trap_type in trap_chances:
|
for trap_type in trap_chances:
|
||||||
trap_chances[trap_type] = 1
|
trap_chances[trap_type] = 1
|
||||||
trap_chances_total = len(trap_chances)
|
trap_chances_total = len(trap_chances)
|
||||||
elif fool:
|
|
||||||
trap_count = 1
|
|
||||||
trap_chances = {'quake': 1}
|
|
||||||
trap_names = {'quake': getattr(self.world, 'trap_chance_quake')[self.player].item_name}
|
|
||||||
trap_chances_total = 1
|
|
||||||
|
|
||||||
def create_trap() -> Item:
|
def create_trap() -> Item:
|
||||||
v = self.world.random.randrange(trap_chances_total)
|
v = self.world.random.randrange(trap_chances_total)
|
||||||
|
|
|
@ -1,13 +1,14 @@
|
||||||
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.1/pyevermizer-0.41.1-cp38-cp38-win_amd64.whl#egg=pyevermizer; sys_platform == 'win32' and platform_machine == 'AMD64' and python_version == '3.8'
|
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.2/pyevermizer-0.41.2-cp38-cp38-win_amd64.whl#egg=pyevermizer; sys_platform == 'win32' and platform_machine == 'AMD64' and python_version == '3.8'
|
||||||
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.1/pyevermizer-0.41.1-cp39-cp39-win_amd64.whl#egg=pyevermizer; sys_platform == 'win32' and platform_machine == 'AMD64' and python_version == '3.9'
|
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.2/pyevermizer-0.41.2-cp39-cp39-win_amd64.whl#egg=pyevermizer; sys_platform == 'win32' and platform_machine == 'AMD64' and python_version == '3.9'
|
||||||
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.1/pyevermizer-0.41.1-cp310-cp310-win_amd64.whl#egg=pyevermizer; sys_platform == 'win32' and platform_machine == 'AMD64' and python_version == '3.10'
|
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.2/pyevermizer-0.41.2-cp310-cp310-win_amd64.whl#egg=pyevermizer; sys_platform == 'win32' and platform_machine == 'AMD64' and python_version == '3.10'
|
||||||
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.1/pyevermizer-0.41.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl#egg=pyevermizer; sys_platform == 'linux' and platform_machine == 'x86_64' and python_version == '3.8'
|
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.2/pyevermizer-0.41.2-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl#egg=pyevermizer; sys_platform == 'linux' and platform_machine == 'x86_64' and python_version == '3.8'
|
||||||
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.1/pyevermizer-0.41.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl#egg=pyevermizer; sys_platform == 'linux' and platform_machine == 'x86_64' and python_version == '3.9'
|
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.2/pyevermizer-0.41.2-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl#egg=pyevermizer; sys_platform == 'linux' and platform_machine == 'x86_64' and python_version == '3.9'
|
||||||
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.1/pyevermizer-0.41.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl#egg=pyevermizer; sys_platform == 'linux' and platform_machine == 'x86_64' and python_version == '3.10'
|
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.2/pyevermizer-0.41.2-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl#egg=pyevermizer; sys_platform == 'linux' and platform_machine == 'x86_64' and python_version == '3.10'
|
||||||
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.1/pyevermizer-0.41.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl#egg=pyevermizer; sys_platform == 'linux' and platform_machine == 'aarch64' and python_version == '3.8'
|
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.2/pyevermizer-0.41.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl#egg=pyevermizer; sys_platform == 'linux' and platform_machine == 'aarch64' and python_version == '3.8'
|
||||||
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.1/pyevermizer-0.41.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl#egg=pyevermizer; sys_platform == 'linux' and platform_machine == 'aarch64' and python_version == '3.9'
|
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.2/pyevermizer-0.41.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl#egg=pyevermizer; sys_platform == 'linux' and platform_machine == 'aarch64' and python_version == '3.9'
|
||||||
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.1/pyevermizer-0.41.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl#egg=pyevermizer; sys_platform == 'linux' and platform_machine == 'aarch64' and python_version == '3.10'
|
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.2/pyevermizer-0.41.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl#egg=pyevermizer; sys_platform == 'linux' and platform_machine == 'aarch64' and python_version == '3.10'
|
||||||
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.1/pyevermizer-0.41.1-cp38-cp38-macosx_10_9_x86_64.whl#egg=pyevermizer; sys_platform == 'darwin' and python_version == '3.8'
|
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.2/pyevermizer-0.41.2-cp38-cp38-macosx_10_9_x86_64.whl#egg=pyevermizer; sys_platform == 'darwin' and python_version == '3.8'
|
||||||
#https://github.com/black-sliver/pyevermizer/releases/download/v0.41.1/pyevermizer-0.41.1-cp39-cp39-macosx_10_9_x86_64.whl#egg=pyevermizer; sys_platform == 'darwin' and python_version == '3.9'
|
#https://github.com/black-sliver/pyevermizer/releases/download/v0.41.2/pyevermizer-0.41.2-cp39-cp39-macosx_10_9_x86_64.whl#egg=pyevermizer; sys_platform == 'darwin' and python_version == '3.9'
|
||||||
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.1/pyevermizer-0.41.1-cp39-cp39-macosx_10_9_universal2.whl#egg=pyevermizer; sys_platform == 'darwin' and python_version == '3.9'
|
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.2/pyevermizer-0.41.2-cp39-cp39-macosx_10_9_universal2.whl#egg=pyevermizer; sys_platform == 'darwin' and python_version == '3.9'
|
||||||
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.1/pyevermizer-0.41.1-cp310-cp310-macosx_10_9_universal2.whl#egg=pyevermizer; sys_platform == 'darwin' and python_version == '3.10'
|
https://github.com/black-sliver/pyevermizer/releases/download/v0.41.2/pyevermizer-0.41.2-cp310-cp310-macosx_10_9_universal2.whl#egg=pyevermizer; sys_platform == 'darwin' and python_version == '3.10'
|
||||||
|
#https://github.com/black-sliver/pyevermizer/releases/download/v0.41.2/pyevermizer-0.41.2.tar.gz#egg=pyevermizer; python_version == '3.11'
|
||||||
|
|
Loading…
Reference in New Issue