bloodypenguin / Skylines-ModTools

Mod debugging/ reverse engineering tool for Cities: Skylines
MIT License
21 stars 15 forks source link

Problem: Values of structs can not be edited with modtools. #10

Open boformer opened 9 years ago

boformer commented 9 years ago

I guess the problem is that the code works like this:

MyStruct structToBeEdited = FooManager.instance.m_foos.m_buffer[x];
structToBeEdited.member = userInput;

Problem is that structToBeEdited is a full copy of a struct, not a reference to the original struct. There are 2 solutions: