Skip to content

Commit

Permalink
Updated Readme
Browse files Browse the repository at this point in the history
Updated automatic map switching to add a settings icon to disable this feature.
  • Loading branch information
powerlord committed Jun 22, 2024
1 parent 867767d commit 738fbbb
Show file tree
Hide file tree
Showing 8 changed files with 104 additions and 24 deletions.
21 changes: 17 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,26 @@
# lisa
Soul Blazer Randomizer tracker using the EmoTracker program.
# Soul Blazer PopTracker Pack
Soul Blazer Randomizer tracker using the PopTracker program. Supports both the standalone and Archipelago versions.

Note: Autotracking support is currently better for the Archipelago veresion, although I intend to work on this later.

## Usage

Upon installing this tracker, use standard operations similar to EmoSaru's ALTTPR tracker: left click items to turn them on, right click to turn them off.
Upon installing this tracker, use standard PopTracker operations: left click items to turn them on, right click to turn them off.
Auto-tracking will override most of the things you can click, though.

The Settings section exists for the map-enabled variants, you toggle these like you would any other checks.

More features are planned for this tracker, and issues can be raised as usual.

## Credits
## PopTrack Pack Credits

These are listed in roughly alphabetical order.

* Black Sliver for making [PopTracker](https://github.com/black-sliver/PopTracker)
* Tranquilite0 for making the [Archipelago version of the randomizer](https://github.com/Tranquilite0/Archipelago-SoulBlazer)
* Wolfman2000 for creating the EmoTracker pack this pack is based on. They also helped locate some memory addresses used for auto-tracking.

## Original EmoTracker Pack Credits

These are listed in roughly alphabetical order.

Expand Down
7 changes: 7 additions & 0 deletions items/randomizersettings.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,12 @@
"type": "toggle",
"img": "images/bosses/deathtollhuman.png",
"codes": "opendeathtoll"
},
{
"name": "Automatic Map Switching",
"type": "toggle",
"img": "images/inventory/pass.png",
"initial_active_state": true,
"codes": "automapswitch"
}
]
2 changes: 2 additions & 0 deletions items_equipment-map_simple/scripts/init-custom.lua
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ for j=1,7 do
Tracker:AddLocations( "locations/world" .. j .. ".json" )
end

Tracker:AddItems( "items/randomizersettings.json" )

Tracker:AddMaps( "maps/maps.json" )

Tracker:AddLayouts( "layouts/tracker_equipment.json" )
Expand Down
2 changes: 2 additions & 0 deletions items_minimal-map_simple/scripts/init-custom.lua
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ for j=1,7 do
Tracker:AddLocations( "locations/world" .. j .. ".json" )
end

Tracker:AddItems( "items/randomizersettings.json" )

Tracker:AddMaps( "maps/maps.json" )

Tracker:AddLayouts( "layouts/tracker.json" )
Expand Down
25 changes: 25 additions & 0 deletions layouts/tracker.json
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,16 @@
]
]
},
"settings_grid": {
"type": "itemgrid",
"h_alignment": "center",
"item_margin": "1,2",
"rows": [
[
"automapswitch"
]
]
},
"tracker_capture_item": {
"type": "container",
"content": {
Expand Down Expand Up @@ -100,6 +110,21 @@
}
]
},
{
"type": "dock",
"dock": "left",
"content": [
{
"type": "group",
"header": "Settings",
"dock": "top",
"content": {
"type": "layout",
"key": "settings_grid"
}
}
]
},
{
"type": "group",
"header": "Pinned Locations",
Expand Down
3 changes: 3 additions & 0 deletions layouts/tracker_archipelago.json
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,9 @@
"goal",
"requiredstonecount",
"opendeathtoll"
],
[
"automapswitch"
]
]
},
Expand Down
25 changes: 25 additions & 0 deletions layouts/tracker_equipment.json
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,16 @@
]
]
},
"settings_grid": {
"type": "itemgrid",
"h_alignment": "center",
"item_margin": "1,2",
"rows": [
[
"automapswitch"
]
]
},
"tracker_capture_item": {
"type": "container",
"content": {
Expand Down Expand Up @@ -120,6 +130,21 @@
}
]
},
{
"type": "dock",
"dock": "left",
"content": [
{
"type": "group",
"header": "Settings",
"dock": "top",
"content": {
"type": "layout",
"key": "settings_grid"
}
}
]
},
{
"type": "group",
"header": "Pinned Locations",
Expand Down
43 changes: 23 additions & 20 deletions scripts/autotracking/mapswitch_simple.lua
Original file line number Diff line number Diff line change
Expand Up @@ -7,26 +7,29 @@ function SwitchMaps( segment )

InvalidateReadCaches()

if AUTOTRACKER_ENABLE_LOCATION_TRACKING then
local mapId = ReadU8( segment, 0x7e1c6a )

if mapId >= 0 then
--print(string.format("Map ID is %#04x", mapId))

if mapId >= 0x78 then
Tracker:UiHint("ActivateTab", "World of Evil")
elseif mapId >= 0x64 and mapId < 0x78 then
Tracker:UiHint("ActivateTab", "Magridd Castle")
elseif mapId >= 0x50 and mapId < 0x64 then
Tracker:UiHint("ActivateTab", "Dr. Leo's Lab")
elseif mapId >= 0x3c and mapId < 0x50 then
Tracker:UiHint("ActivateTab", "Mountain of Souls")
elseif mapId >= 0x28 and mapId < 0x3c then
Tracker:UiHint("ActivateTab", "Seabed Sanctuary")
elseif mapId >= 0x14 and mapId < 0x28 then
Tracker:UiHint("ActivateTab", "Woods of Greenwood")
elseif mapId >= 0x00 and mapId < 0x0f then
Tracker:UiHint("ActivateTab", "Grass Valley")
if AUTOTRACKER_ENABLE_LOCATION_TRACKING then

if Tracker:ProviderCountForCode( "automapswitch" ) > 0 then
local mapId = ReadU8( segment, 0x7e1c6a )

if mapId >= 0 then
--print(string.format("Map ID is %#04x", mapId))

if mapId >= 0x78 then
Tracker:UiHint("ActivateTab", "World of Evil")
elseif mapId >= 0x64 and mapId < 0x78 then
Tracker:UiHint("ActivateTab", "Magridd Castle")
elseif mapId >= 0x50 and mapId < 0x64 then
Tracker:UiHint("ActivateTab", "Dr. Leo's Lab")
elseif mapId >= 0x3c and mapId < 0x50 then
Tracker:UiHint("ActivateTab", "Mountain of Souls")
elseif mapId >= 0x28 and mapId < 0x3c then
Tracker:UiHint("ActivateTab", "Seabed Sanctuary")
elseif mapId >= 0x14 and mapId < 0x28 then
Tracker:UiHint("ActivateTab", "Woods of Greenwood")
elseif mapId >= 0x00 and mapId < 0x0f then
Tracker:UiHint("ActivateTab", "Grass Valley")
end
end
end
end
Expand Down

0 comments on commit 738fbbb

Please sign in to comment.