Solved Hook void string LGL menu

Status
Not open for further replies.

Kenjaaaa45

Platinian
Original poster
Apr 9, 2022
21
1
3
23
France
Hi evryone, im not posting alot, but I would like to know if anyone has the solution to help for hook a void string function in my lgl project using InputText


// RVA: 0xE48E87Offset: 0xE48E87
private void OnHashtagSubmit(string hashtag) { }

It work without update offset but i have no idea how do that, i have test some little code from another forum but nothing worked.

Thanks you.
 

Kenjaaaa45

Platinian
Original poster
Apr 9, 2022
21
1
3
23
France
void playername(void* instance) {
if (instance != nullptr) {
if (inputText != nullptr) {
OnHashtagSubmit(inputText);
return;
}
}
old_playername(instance);
}
 

mIsmanXP

Approved Modder
Approved Modder
Feb 20, 2022
205
8,890
193
Republic of Indonesia
I assume you don't know where to get inputText, if so refer to this thread
If a function accept a string, it's actually a C# System.String, not just a regular "string like this inside double quote"
 

Kenjaaaa45

Platinian
Original poster
Apr 9, 2022
21
1
3
23
France
I know where get inputText ! But only work for String offset, what i want its hook void(string) which I will use with InputText like this the value will only change when I put a value in the input text
 

mIsmanXP

Approved Modder
Approved Modder
Feb 20, 2022
205
8,890
193
Republic of Indonesia
sorry, can you explain more what you are trying to do?
maybe write it in your language and use google translate cause you are not making sense (sorry)
 

Kenjaaaa45

Platinian
Original poster
Apr 9, 2022
21
1
3
23
France
sorry, can you explain more what you are trying to do?
maybe write it in your language and use google translate cause you are not making sense (sorry)
// RVA: 0xE48E44 Offset: 0xE48E44 VA: 0xE48E44
private void OnHashtagSubmit(string hashtag) { }
I want to hook this function in
my lgl 2.9 project but I don't know how to do it
 

DaRealPanDa

Co-Administrator
Staff member
Supporting-Team
Global Moderator
Social Media
Mar 12, 2018
6,771
15,650
2,120
27
Skyrim
Thread will be set to "solved" and closed.
When you're not happy with that just send me a message and i will re-open the thread for you.

Thanks.
 
Status
Not open for further replies.