-
Notifications
You must be signed in to change notification settings - Fork 53
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
Feat: Area Ranks #671
base: develop
Are you sure you want to change the base?
Feat: Area Ranks #671
Conversation
Arrowgene.Ddon.GameServer/Chat/Command/Commands/AreaPointCommand.cs
Outdated
Show resolved
Hide resolved
Arrowgene.Ddon.Shared/Entity/Structure/CDataCycleContentsRank.cs
Outdated
Show resolved
Hide resolved
{ | ||
19 => true, | ||
20 => false, | ||
_ => throw new ResponseErrorException(ErrorCode.ERROR_CODE_AREAMASTER_INVALID_SUPPLY_STORAGE), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We've seen this 19/20 values meaning to bag/to storage a lot, maybe it should be time to move them into an enum? 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree, but do we know what it really means?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Besides 19 meaning bag and 20 being storage, not really, maybe the mobile app has some answers
Arrowgene.Ddon.GameServer/Handler/AreaGetAreaSupplyInfoHandler.cs
Outdated
Show resolved
Hide resolved
Arrowgene.Ddon.GameServer/Handler/AreaGetLeaderAreaReleaseListHandler.cs
Outdated
Show resolved
Hide resolved
Arrowgene.Ddon.GameServer/Handler/AreaGetLeaderAreaReleaseListHandler.cs
Outdated
Show resolved
Hide resolved
{ | ||
19 => true, | ||
20 => false, | ||
_ => throw new ResponseErrorException(ErrorCode.ERROR_CODE_AREAMASTER_INVALID_SUPPLY_STORAGE), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree, but do we know what it really means?
@@ -61,8 +65,16 @@ | |||
{ | |||
"type": "MyQstFlags", | |||
"announce_type": "Accept", | |||
"set_flags": [ 6 ], | |||
"check_flags": [ 1, 2, 3, 4, 5 ] | |||
"set_flags": [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These JSON formatting changes made to all these quests makes it harder to read which is important since we are hand writing all these quests.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The problem is that any change I make programmatically re-formats the JSON to "standard" JSON. Maybe there's some option in Python's json
module that I'm not using, but the alternative is hand-adding rewards to 237 world quests, or doing area-points programmatically on deserializing the asset, which I didn't like conceptually.
…when using a master craft pawn, clean up skill assets, fix missing serializer from sebastian-heinz#671.
throw new ResponseErrorException(ErrorCode.ERROR_CODE_AREAMASTER_SUPPLY_NOT_AVAILABLE, $"No valid asset for {areaId} found in AreaRankSupply asset."); | ||
} | ||
|
||
var rankSupplies = areaSupplies.Where(x => x.MinRank <= rank).OrderBy(x => x.MinRank).LastOrDefault(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't it be better to use Single() instead so it also throws an exception if there's more than one?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, because you want the last one that you qualify for.
areaSupplies
.Where(x => x.MinRank <= rank) // Get all qualifying supply sets; this is usually multiple if your rank is higher than 4 or so, depending on area.
.OrderBy(x => x.MinRank) // Sort from lowest required rank to highest.
.LastOrDefault() // Take the highest rank qualifying supply set.
throw new ResponseErrorException(ErrorCode.ERROR_CODE_AREAMASTER_SUPPLY_NOT_AVAILABLE, $"No valid asset for {areaId}, rank {rank} found in AreaRankSupply asset."); | ||
} | ||
|
||
var pointSupplies = rankSupplies.SupplyItemInfoList.Where(x => x.MinAreaPoint <= points).OrderBy(x => x.MinAreaPoint).LastOrDefault(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
Arrowgene.Ddon.GameServer/Handler/AreaGetAreaBaseInfoListHandler.cs
Outdated
Show resolved
Hide resolved
- Find packet which controls area rank. - Implement req/res packets for area rank.
…GameRequestPacketHandlers.
… GameRequestPacketHandler; cleanup useless quests from that pcap.
…ieving supply goods, and other area rank mechanics.
…lues based on wiki-crawling.
…ions to Area Rank handlers.
ee1c2a5
to
d1507fc
Compare
d1507fc
to
a926307
Compare
…opagate properly; fix DC when handing in delivery quests.
Implements Area Ranks and their associated unlocks.
ddon_area_rank
and waiting supply itemsddon_area_rank_supply
./areapoint [areaId] [amount]
as a debug command.AreaRankSpotInfoAsset
,AreaRankRequirementAsset
, andAreaRankSupplyAsset
.SpotInfo
andRequirement
assets are serverside copies of information the client uses in the UI without prompting. These "define" what things unlock when, and what point totals or quests are needed to progress to a certain rank. As such, these largely should not be altered.Supply
asset defines the slate of area rank supply rewards for combinations of weekly point totals and area rank. These can be freely altered.PointType
.floor(level/5)
. It's AP is then5*tier^2 + 5*tier + 30
.10*tier^2 + 10*tier + 30
Existing world and board quests have had AP rewards added based on this curve. This is why it touches 700+ files, sorry.EnableAreaRankSpotLocks
has been added to the GameLogicSettings. When this istrue
, the full area rank system is implemented. Whenfalse
, all spot unlocks are granted automatically; this does cause some UI weirdness with the Area List, but should be functionally fine.To-Do:
AreaGetAreaQuestHintListHandler
is a very bizarre system and the way that we track quests and alert the client to them is somehow not working the way it wants. Luckily, this system is dumb and terrible, and we can probably safely ignore it.Checklist:
develop
branch