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

Thief Shrine didn't autosplit #33

Open
ak505188 opened this issue May 19, 2022 · 6 comments
Open

Thief Shrine didn't autosplit #33

ak505188 opened this issue May 19, 2022 · 6 comments

Comments

@ak505188
Copy link
Collaborator

https://clips.twitch.tv/ArtsySuaveLorisTwitchRPG-O0lGvBg-53ktF-bb

@Eein
Copy link
Owner

Eein commented May 28, 2022

When i find some time this week i'll try and poke through the ue4 objects and see if theres a flag for shrines. This is likely caused by gamestate race condition

@Eein
Copy link
Owner

Eein commented May 28, 2022

namespace CG
{
	// --------------------------------------------------
	// # Structs
	// --------------------------------------------------
	/**
	 * UserDefinedStruct JobData.JobData
	 * Size -> 0x00D8
	 */
	struct FJobData
	{
	public:
		int32_t                                                    JobID_25_835C06C94E7904242C877DB7D3579559;               // 0x0000(0x0004) Edit, BlueprintVisible, ZeroConstructor, IsPlainOldData, NoDestructor, HasGetValueTypeHash
		unsigned char                                              UnknownData_RQBM[0x4];                                   // 0x0004(0x0004) MISSED OFFSET (FIX SPACE BETWEEN PREVIOUS PROPERTY)
		class FName                                                DisplayName_18_77B530904814B906512A3EBD091FB621;         // 0x0008(0x0008) Edit, BlueprintVisible, ZeroConstructor, IsPlainOldData, NoDestructor, HasGetValueTypeHash
		class FName                                                Detail_19_03B4421B4568CC1E9D8B3D936D3D1BCF;              // 0x0010(0x0008) Edit, BlueprintVisible, ZeroConstructor, IsPlainOldData, NoDestructor, HasGetValueTypeHash
		int32_t                                                    DisplayOrder_67_07963AD444D43D43F4F22E8F9C9CF845;        // 0x0018(0x0004) Edit, BlueprintVisible, ZeroConstructor, IsPlainOldData, NoDestructor, HasGetValueTypeHash
		unsigned char                                              UnknownData_RSNB[0x4];                                   // 0x001C(0x0004) MISSED OFFSET (FIX SPACE BETWEEN PREVIOUS PROPERTY)
		class FName                                                MenuJobIcon_60_BA3AA57849D7DBA951B7F2850915A839;         // 0x0020(0x0008) Edit, BlueprintVisible, ZeroConstructor, IsPlainOldData, NoDestructor, HasGetValueTypeHash
		class FName                                                AbilityJobIcon_63_7C7C07184E2FBF2CCCA32B957C42BA4C;      // 0x0028(0x0008) Edit, BlueprintVisible, ZeroConstructor, IsPlainOldData, NoDestructor, HasGetValueTypeHash
		int32_t                                                    PermissionFlag_31_A5FBA63449C3EF0ED7BE1393385B212B;      // 0x0030(0x0004) Edit, BlueprintVisible, ZeroConstructor, IsPlainOldData, NoDestructor, HasGetValueTypeHash
		unsigned char                                              UnknownData_342H[0x4];                                   // 0x0034(0x0004) MISSED OFFSET (FIX SPACE BETWEEN PREVIOUS PROPERTY)
		TArray<bool>                                               ProperEquipment_22_ECDE8975414CC31E67313ABA713C22FE;     // 0x0038(0x0010) Edit, BlueprintVisible, ZeroConstructor
		TArray<EEQUIPMENT_CATEGORY_EEQUIPMENT_CATEGORY>            EquipArmorPriority_53_F7C8724E49CA9F32E20737A4ADF0B82A;  // 0x0048(0x0010) Edit, BlueprintVisible, ZeroConstructor
		TArray<EEQUIPMENT_CATEGORY_EEQUIPMENT_CATEGORY>            EquipHelmetPriority_54_15EDDD95470C83EF30FDFCB36FC5E17A; // 0x0058(0x0010) Edit, BlueprintVisible, ZeroConstructor
		struct FCharacterParam                                     ParameterRevision_9_5F8998A541B5EAF310E2C9A623913B9A;    // 0x0068(0x0030) Edit, BlueprintVisible, HasGetValueTypeHash
		class FName                                                JobCommandName_28_A46F72BD4EB629A96FD206AC6E110899;      // 0x0098(0x0008) Edit, BlueprintVisible, ZeroConstructor, IsPlainOldData, NoDestructor, HasGetValueTypeHash
		class FName                                                JobCommandDetail_34_04FCC32E4AE8E7290F420E92B1AAA9CE;    // 0x00A0(0x0008) Edit, BlueprintVisible, ZeroConstructor, IsPlainOldData, NoDestructor, HasGetValueTypeHash
		TArray<struct FJobLearnAbility>                            JobCommandAbility_43_DA2767AE4E0EF10EB9784CBDF68B42F2;   // 0x00A8(0x0010) Edit, BlueprintVisible, ZeroConstructor
		TArray<struct FJobLearnAbility>                            JobSupportAbility_42_641BDABF417D5189F1230CBD6276F10E;   // 0x00B8(0x0010) Edit, BlueprintVisible, ZeroConstructor
		TArray<int32_t>                                            JPCost_41_39D417E148D407A63AC22FA2F9F2FA9A;              // 0x00C8(0x0010) Edit, BlueprintVisible, ZeroConstructor

	};

}

#ifdef _MSC_VER
	#pragma pack(pop)
#endif

PermissionFlag_31_A5FBA63449C3EF0ED7BE1393385B212B looks interesting

@Eein
Copy link
Owner

Eein commented May 28, 2022

class USubJobWidget_C : public UUserWidget
also a good candidate

@Eein
Copy link
Owner

Eein commented May 28, 2022

JobSupportAbility_42_641BDABF417D5189F1230CBD6276F10E is a good target according to https://github.com/MarvinXLII/OctopathTravelerJobRandomizer/blob/main/src/Data.py#L511

@Eein
Copy link
Owner

Eein commented May 28, 2022

After doing additional research i'm convinced they do not store the actual job aquisition flag -
It's probably simply checking if abilities are unlocked (or available to be unlocked) instead of setting a flag. I'll dive further into this at a later time.

edit:
i've been through savedata, character libs, battlemanager, the subjob widgets, and jobdata tables etc - so i'm very likely missing something very important or there is some really spaghetti way the game decides if a job is available...

@Eein
Copy link
Owner

Eein commented May 28, 2022

libcharacter

		void STATIC_CheckJobAbilityComplete(int32_t CharacterID, class UObject* __WorldContext, bool* Complete, int32_t* RestComplete);
		void STATIC_GetAbilityAcquisitionList(int32_t CharacterID, int32_t JobID, class UObject* __WorldContext, TArray<bool>* AcquisitionList);
		void STATIC_AcquisitionSupportAbility(int32_t CharacterID, int32_t JobID, class UObject* __WorldContext, TArray<struct FJobLearnAbility>* AcquisitionAbility);
		void STATIC_GetJobAcquisitionCommandAbilityNum(int32_t CharacterID, int32_t JobID, class UObject* __WorldContext, int32_t* AcquisitionNum);

has potential maybe...
I wont be able to get into this reliably - so we might have to ponder a better way to track these

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

No branches or pull requests

2 participants