Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Only enable Missile Reserve Tank if Missile Launcher is in inventory #280

Merged
merged 3 commits into from
Feb 21, 2024

Conversation

dyceron
Copy link
Collaborator

@dyceron dyceron commented Feb 21, 2024

Given the current implementation of shuffled Missile Launcher, this is the simplest solution to preventing the Missile Reserve Tank from activating on its own without Missiles. Now, it checks for Missile Launcher in the inventory to activate. The only downside is that having only Super Launcher means you can't utilize the Reserve Tank to your advantage. Maybe in the future we can have the Reserve Tank be independent of the Launcher, but this is the best option I'm willing to take for now.

Fixes #253

@dyceron dyceron requested a review from ThanatosGit February 21, 2024 00:34
Comment on lines 27 to 33
if _FORV_3_ == "ITEM_RESERVE_TANK_MISSILE" and Blackboard.GetProp("PLAYER_INVENTORY", "ITEM_WEAPON_MISSILE_LAUNCHER") then
Blackboard.SetProp("GAME", "ITEM_RESERVE_TANK_MISSILE_ACTIVE", "b", true)
Blackboard.SetProp("GAME", "ITEM_RESERVE_TANK_MISSILE_FULL", "b", true)
elseif _FORV_3_ ~= "ITEM_RESERVE_TANK_MISSILE" then
Blackboard.SetProp("GAME", _FORV_3_ .. "_ACTIVE", "b", true)
Blackboard.SetProp("GAME", _FORV_3_ .. "_FULL", "b", true)
end
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Both flows doing the exact same thing. Can just be combined in one if-clause with an or.

@ThanatosGit ThanatosGit merged commit d1d065e into main Feb 21, 2024
5 checks passed
@dyceron dyceron deleted the lock-missile-reserve-tank branch February 21, 2024 22:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Missile Reserve Tank activates on scenario load and unpausing
2 participants