mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2026-11-18 09:45:28 +00:00
LWOMissionComponent::MissionWindowOK (0x00d501f0) turns a mission in only when CanReceiveAllRewards (msgCanReceiveAllRewards 0x00d17e20, sub_00d17750) passes for the reward the player picked: the reward items (the repeat ones once completed, each at least 1) must fit after the items the tasks take (a gather task's target unless it keeps them, one of a delivery task's target) with the first completion's bag rewards added. The fit is LWOInventoryComponent_Common::CheckCanAddItems (0x00d53de0): turned in items leave first (an item of 1 settles the whole count), a unique item fails while one is held outside the buyback, then each item tops up stacks of its LOT (stack size 0 is no limit, LookupItemInfo 0x00c1c190) and takes free slots. MissionDialogueOK now refuses a turn-in that does not pass, which the client never sends. The client's max currency part is not checked: the server writes no cm, so the client has no limit either. InventoryComponent::GetDefaultInventorySize is split out of GetInventory. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
46 lines
1.4 KiB
CMake
46 lines
1.4 KiB
CMake
set(DCOMPONENTS_TESTS
|
|
"DeletionRestrictionTests.cpp"
|
|
"MovingPlatformComponentTests.cpp"
|
|
"InventorySaveTests.cpp"
|
|
"EquipMessagesTests.cpp"
|
|
"DestroyableLevelConfigTests.cpp"
|
|
"RailActivatorComponentTests.cpp"
|
|
"VendorBuybackTests.cpp"
|
|
"RacingWrongWayTests.cpp"
|
|
"DestroyableComponentTests.cpp"
|
|
"PetComponentTests.cpp"
|
|
"SimplePhysicsComponentTests.cpp"
|
|
"MovementBlockerScenarioTests.cpp"
|
|
"SavingTests.cpp"
|
|
"CharacterSaveFieldsTests.cpp"
|
|
"CollectibleComponentTests.cpp"
|
|
"MissionOfferTests.cpp"
|
|
"MissionClientRulesTests.cpp"
|
|
"MissionRewardSpaceTests.cpp"
|
|
"ReplicaComponentOrderTests.cpp"
|
|
"QuickBuildCompleteTests.cpp"
|
|
"RocketLaunchTests.cpp"
|
|
"ReplicaConstructionTests.cpp"
|
|
"ReplicaDecoderTests.cpp"
|
|
"CapturePropertyTests.cpp"
|
|
"InventoryGroupTests.cpp"
|
|
"InventoryMoveTests.cpp"
|
|
"ItemRemovalTests.cpp"
|
|
"UseItemResultTests.cpp"
|
|
"LootMetricsTests.cpp"
|
|
"SpawnerComponentTests.cpp"
|
|
"SkillComponentTests.cpp"
|
|
)
|
|
|
|
# Get the folder name and prepend it to the files above
|
|
get_filename_component(thisFolderName ${CMAKE_CURRENT_SOURCE_DIR} NAME)
|
|
list(TRANSFORM DCOMPONENTS_TESTS PREPEND "${thisFolderName}/")
|
|
|
|
# Export to parent scope
|
|
set(DCOMPONENTS_TESTS ${DCOMPONENTS_TESTS} PARENT_SCOPE)
|
|
|
|
# Copy test files to testing directory
|
|
add_subdirectory(TestData)
|
|
list(TRANSFORM COMPONENT_TEST_DATA PREPEND "${thisFolderName}/")
|
|
set(COMPONENT_TEST_DATA ${COMPONENT_TEST_DATA} PARENT_SCOPE)
|