Help! Help please

raeivsky234

Platinian
public static GarageCarData AddOnlineCar(string prefab, string name, string instanceID, ObscuredInt sellPrice, byte[] data)

How can I intercept the obscured value in the sell price parameters
 
Last edited:
Obscured stuff is a codestage anticheat thing. You will have to figure out how to bypass the anticheat.

You will need to build a struct for obscured in order to modify obscured values. It is a more advanced modding and not a easy task for new modders.

Best bet is take your time to learn more about modding and possibly find a game that doesn't have an anticheat to start out on.
 
Obscured stuff — это codestage античит. Вам придется придумать, как обойти античит.

Вам нужно будет построить структуру для obscured, чтобы изменить значения obscured. Это более продвинутый моддинг и непростая задача для новых моддеров.

Лучший вариант — уделить время изучению моддинга и, по возможности, найти игру, в которой нет античита, для начала.
There the anti-cheat does not work, I calmly change the obscured field values, so I need to know how to change the obscured parameter
 
You say you know how to modify

ObscuredInt sellPrice

The obscuredint part. If you have and it didnt work then its not going to work. thats part of the codestage anticheat process. Sometimes modifiying the ObscuredInt etc doesnt work and sometimes it does. If it does then good. if it doesn't then you'll need to bypass codestage anticheat. Which you will need to figure out how to do yourself.
 
Вы говорите, что знаете, как модифицировать

ObscuredInt цена продажи

Часть obscuredint. Если у вас есть и это не сработало, то это не сработает. Это часть процесса codestage anticheat. Иногда изменение ObscuredInt и т. д. не работает, а иногда работает. Если работает, то хорошо. Если нет, то вам нужно обойти codestage anticheat. Что вам нужно будет выяснить самостоятельно.
Codestage anti-cheat is not configured for hidden values because I change the fields as I want and to what I want I do not know how to change the hidden value in the method parameters that's all
 
Было бы проще, если бы я мог увидеть ваш текущий крючок для этого.
void (*old_AddOnlineCar)(monoString* prefab, monoString* name, monoString* instanceID, int sellPrice, byte* data);

old_AddOnlineCar(CreateString("STRING_B"), CreateString("STRING B"), CreateString("STRING"), 1, nullptr);

old_AddOnlineCar = (void(*)(monoString*, monoString*, monoString*, int, byte*)) getAbsoluteAddress(targetLibName, 0xD5C5F4);
 
void (*old_AddOnlineCar)(monoString* prefab, monoString* name, monoString* instanceID, int sellPrice, byte* data);

old_AddOnlineCar(CreateString("STRING_B"), CreateString("STRING B"), CreateString("STRING"), 1, nullptr);

old_AddOnlineCar = (void(*)(monoString*, monoString*, monoString*, int, byte*)) getAbsoluteAddress(targetLibName, 0xD5C5F4);
Yeah you can't modify obscuredint etc that way. You have to make a custom struct to be able to mod it which requires looking at the obscured struct in codestage anticheat.
 
Yeah you can't modify obscuredint etc that way. You have to make a custom struct to be able to mod it which requires looking at the obscured struct in codestage anticheat.
struct ObscuredInt {
private:
static int cryptoKey;
int currentCryptoKey;
int fakeValue;
bool fakeValueActive;
int hiddenValue;
bool inited;
};

void SetObscuredIntValue(uintptr_t location, int value){
int cryptoKey = *(int *)location;

*(int *)(location + 0x4) = value ^ cryptoKey;
}

void (*old_AddOnlineCar)(monoString* prefab, monoString* name, monoString* instanceID, ObscuredInt* sellPrice, byte* data);

if (btn1) {
uintptr_t test = 0xB0B76C;
old_AddOnlineCar(CreateString("STRING_B"), CreateString("STRING B"), CreateString("STRING"), SetObscuredIntValue(test, 1000000), nullptr);
}

old_AddOnlineCar = (void(*)(monoString*, monoString*, monoString*, ObscuredInt*, byte*)) getAbsoluteAddress(targetLibName, 0xD5CA54);
 
Try using this as a reference, correct/modify it if necessary.

C++:
struct ObscuredInt {
    // static int cryptoKey;           // Static field: cryptoKey
    int currentCryptoKey;           // offset: 0x0
    int hiddenValue;                // offset: 0x4
    bool inited;                    // offset: 0x8
    char pad1[3];                   // padding to align next field
    int fakeValue;                  // offset: 0xC
    bool fakeValueActive;           // offset: 0x10
    // char pad2[3];                   // more padding if needed
};

ObscuredInt CreateObscuredInt(int value, int cryptoKey) {
    ObscuredInt o;
    o.currentCryptoKey = cryptoKey;
    o.hiddenValue = value ^ cryptoKey;
    o.inited = true;
    o.fakeValue = value;
    o.fakeValueActive = false;
    return o;
}

When using CreateObscuredInt make sure you have the right crypto key. For testing, passing 1 or 2 should work
 
Try using this as a reference, correct/modify it if necessary.

C++:
struct ObscuredInt {
    // static int cryptoKey;           // Static field: cryptoKey
    int currentCryptoKey;           // offset: 0x0
    int hiddenValue;                // offset: 0x4
    bool inited;                    // offset: 0x8
    char pad1[3];                   // padding to align next field
    int fakeValue;                  // offset: 0xC
    bool fakeValueActive;           // offset: 0x10
    // char pad2[3];                   // more padding if needed
};

ObscuredInt CreateObscuredInt(int value, int cryptoKey) {
    ObscuredInt o;
    o.currentCryptoKey = cryptoKey;
    o.hiddenValue = value ^ cryptoKey;
    o.inited = true;
    o.fakeValue = value;
    o.fakeValueActive = false;
    return o;
}

When using CreateObscuredInt make sure you have the right crypto key. For testing, passing 1 or 2 should work
thank you very much and you don't know how to pass the parameter byte[] data and data type of the garagecardata
 

Attachments

  • Снимок.JPG
    Снимок.JPG
    48.4 KB · Views: 6
  • Снимок.JPG
    Снимок.JPG
    90.4 KB · Views: 6
thank you very much and you don't know how to pass the parameter byte[] data and data type of the garagecardata
for data which is a byte[] type, you can try defining it as:

C++:
monoArray<uint8_t>* data

And then assuming you're only returning GarageCarData and not interacting with it, you can simply return it as a void*

Sorry if I didn't get what you said. Tell me if i did, and ty adding more context.
 
для данных типа byte[] можно попробовать определить их как:

C++:
monoArray<uint8_t>* данные

И затем, предположив, что вы возвращаете только GarageCarData и не взаимодействуете с ним, вы можете просто вернуть его как void*

Извините, если я не понял, что вы сказали. Скажите мне, если я понял, и добавьте больше контекста.
This is a custom data type, I don't even know if it is used, but in the il2cpp tool this method works perfectly, please show me if it is not difficult for you how to completely pass the data parameter and also for verification how to use this data type GarageCarData
 
struct GarageCarData {
private:
void* type_info;
void* reserved;
public:
bool BetaSave;
ObscuredInt CoinsSellPrice;
ObscuredInt CoinsSubtractAmount;
monoString* DeviceId;
ObscuredInt GoldSubtractAmount;
monoString* ID;
monoString* InstanceID;
monoString* Name;
monoString* Prefab;
bool SkipOnSync;
bool UpdateIcon;
bool _synchronize;
};

GarageCarData* (*old_AddOnlineCar)(monoString* prefab, monoString* name, monoString* instanceID, ObscuredInt sellPrice, byte* data);

old_AddOnlineCar = (GarageCarData*(*)(monoString*, monoString*, monoString*, ObscuredInt, byte*)) getAbsoluteAddress(targetLibName, 0xD5CA54);
 
Back
Top Bottom