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

Missionrefactor #41

Merged
merged 22 commits into from May 30, 2017
Merged

Missionrefactor #41

merged 22 commits into from May 30, 2017

Conversation

gcabbage
Copy link
Contributor

See: Mission Refactor: Phase II. This PR updates more code to use MissionType and Language tags including: Charon, Battle Arena, St Kats, Black Market, Hotel

Includes some changes to RPGLibrary:

  • New function rpgMissionGetAssignment is basically a copy of rpgMissionAssignment which returns the mission object rather than displaying the dockscreen. This is intended for cases where we need to run station code / display other dockscreens where there are no missions rather than just display a simple message.
  • New mission attribute "paneInitMission" similar to "deliveryMission", but using OnGlobalPaneInit. Used for black market delivery and Katami kidnap.
  • New function rpgCharacterIsKnown to check if player has met a character. Some missions were using rpgCharacterGetQuickRel to check if the character had been met, but in many cases a known character will still have a Nil relationship. See 71781. Alternatively rpgCharacterGetQuickRel could be changed to only return Nil for never met characters.

Copy link
Member

@gmoromisato gmoromisato left a comment

Choose a reason for hiding this comment

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

A couple of minor comments:

  1. I'm not sure adding "sistersMission" is a good idea. This will cause those missions to appear at any Sisters station, but we probably want to restrict Benedict missions to certain systems (Eridani and Tau Ceti).

  2. I think I'd rather fix rpgCharacterGetQuickRel than introduce a new function. If there are some missions that don't set the relationship properly, we should do that. Or maybe rpgCharacterGetQuickRel should return "favorable" if there is no relationship but firstPlayerMeetingTime is set.

@gcabbage
Copy link
Contributor Author

Currently Benedict00 will only spawn in startingSystem; 03 is restricted to SE; 01 and 02 are not restricted by system (all four are level="1")

How about making them all startingSystem only?

@gmoromisato
Copy link
Member

Yeah, that makes sense. You're proposing:

  1. Leave sistersMission attribute on 00, 01, 02, and 03.
  2. Change missions 01, 02, and 03 to only appear in startingSystem (by checking in ).

I agree with that; please go ahead and make those changes. Thank you!

@gcabbage
Copy link
Contributor Author

I think I'd rather fix rpgCharacterGetQuickRel than introduce a new function. If there are some missions that don't set the relationship properly, we should do that. Or maybe rpgCharacterGetQuickRel should return "favorable" if there is no relationship but firstPlayerMeetingTime is set.

I've changed rpgCharacterGetQuickRel to only return Nil if the character has not been met. As currently rpgCharacterChangeRel does not have an event for "said hello, but did not do anything important yet"

Alternatively we could change rpgCharacterSetMeeting to replace a Nil relationship with notSet

@gmoromisato gmoromisato merged commit 95226c7 into kronosaur:master May 30, 2017
@gmoromisato
Copy link
Member

Looks good! I've merged into master.

Thank you! I'm really happy with this refactoring.

@gcabbage gcabbage deleted the missionrefactor branch June 11, 2017 18:05
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.

None yet

2 participants