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

Add Restarting Missions #173

Merged
merged 9 commits into from
Feb 22, 2021
Merged

Add Restarting Missions #173

merged 9 commits into from
Feb 22, 2021

Conversation

TheNexusAvenger
Copy link
Member

Closes #169

This pull request adds the ability to restart completed missions, such as daily missions or helper missions in Nexus Tower. This also includes a fix for a bug I introduced with returning items in the Laser Rampage/Wrecking Crew not working due to a wrong condition operator.

The change was developed on enhancement/reduce-load-time and the changes were moved over to a different branch. The changes were tested by manually changing the completion time of a daily mission (id 1858 especially) in the database to be an older time to allow for the mission to be re-obtained. The mission was re-obtained, re-completed, and the incrementer in the database of how many times it completed went up.

Copy link
Member

@Jettford Jettford left a comment

Choose a reason for hiding this comment

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

Changes to the CDClient are not a good idea

@TheNexusAvenger
Copy link
Member Author

The changes to CDClient were reverted. The intent with the change was to ensure that the cooldowns for daily missions would be valid while keeping the 4 repeatable missions in Nexus Tower at no cooldown as they are helper missions. However, I realized that those 4 missions are the only missions that are not in InMOTD with no cooldown. The case that corrects the time to 22 hours does not affect those missions, while fixing the missions in Avant Gardens.

@MickVermeulen
Copy link
Member

Nice addition, only downside would be your use of the UchuContext as that isn't required after the refractor is merged. Either way, you're done earlier than me so I'll port this to the refactor once I find the time.

@TheNexusAvenger
Copy link
Member Author

After some discussion in the LEGO Universe Community Hub, it was found that repeatable missions must use a mission state that is 8 + the normal mission state, which the current code does not do. There are a few missions preconditions that specify the 8 + (normal state) instead of just the normal state. This shouldn't be too bad, mainly changing RestartAsync to set a different state, but the change may be more involved.

@MickVermeulen
Copy link
Member

Thanks for the comment! I'll take that into account when I reimplement this.

…eatable-missions

� Conflicts:
�	Uchu.StandardScripts/AvantGardens/LaserRampageReturn.cs
�	Uchu.World/Objects/Components/Player/MissionInventoryComponent.cs
�	Uchu.World/Systems/Missions/MissionInstance.cs
Copy link
Member

@MickVermeulen MickVermeulen left a comment

Choose a reason for hiding this comment

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

Really nice work, no comments!

@MickVermeulen MickVermeulen merged commit 9b16fb4 into dev Feb 22, 2021
@MickVermeulen MickVermeulen deleted the enhancement/repeatable-missions branch February 22, 2021 09:38
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.

Missions Of The Day Don't Reset The Next Day
3 participants