Help! How To use byte in field offset ?

CHEATS GAMES

Solid & Active Platinian
Original poster
Aug 9, 2019
64
18
8
39
Brazil
C++:
    // Token: 0x040088BB RID: 35003
        [Token(Token = "0x40088BB")]
        [FieldOffset(Offset = "0x18")]
        public byte OwnerPlayerId;
C++:
 byte OwnerPlayerId = *(byte*)((uint64_t)instance + 0x18); //public int teamID;
1650639900948.png
 

NullCoder

Inactive Approved Modder
Jun 8, 2020
110
902
93
21
None
Honestly... I look at this and am amazed that people are trying to do something without even knowing what data types are in the C++ language and how they differ in general. Are you trying to take an int variable in bool? Are you trying to make this bool in byte afterwards? Do you even understand what nonsense you are doing? Before you climb, understand at least the elementary things!
 

CHEATS GAMES

Solid & Active Platinian
Original poster
Aug 9, 2019
64
18
8
39
Brazil
Honestly... I look at this and am amazed that people are trying to do something without even knowing what data types are in the C++ language and how they differ in general. Are you trying to take an int variable in bool? Are you trying to make this bool in byte afterwards? Do you even understand what nonsense you are doing? Before you climb, understand at least the elementary things!

no dude,, haha, ignore this, was doing something else, forgot to change this to post
 

Tiahh

Solid & Active Platinian
Jan 12, 2018
79
46
18
37
Try this:
C++:
int ownerId = *(int*)((uint64_t)instance+0x18);