Posted February 6, 20223 yr I have been trying to make a help message in rdr2 appear for days now but no matter what I do it just keeps crashing. Here is my code in c# by the way. argasd1.p0 = duration; argasd1.p1 = 0; argasd1.p2 = 0; argasd1.p3 = 0; argasd2.p0 = 0; argasd2.p1 = Function.Call<string>(Hash._CREATE_VAR_STRING, 10, "LITERAL_STRING", message); Function.Call<string>(Hash._0x049D5C615BD38BAD, argasd1.p0, argasd2.p1, 1); Does anyone know what I am doing wrong?
February 6, 20223 yr Try changing the return type of your call to CREATE_VAR_STRING to long instead of string. Also pass the actual structures as parameters, not values from the structures).
February 7, 20223 yr Author On 2/6/2022 at 4:40 PM, LMS said: Try changing the return type of your call to CREATE_VAR_STRING to long instead of string. Also pass the actual structures as parameters, not values from the structures). Ok, I changed the return type to long, but what do you mean by "pass the actual structures as parameters, not values from the structures)."? Could you provide an example?
February 7, 20223 yr Author On 2/6/2022 at 4:40 PM, LMS said: Try changing the return type of your call to CREATE_VAR_STRING to long instead of string. Also pass the actual structures as parameters, not values from the structures). Passing the stucts as params gives me an error
February 9, 20223 yr Try passing them as a pointer (using &) or casting to long instead. Your problem is that you are passing individual values from the structure, not the structure itself.
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.