❔ Value types keep on changing??
I have been dealing with this problem for a few days and couldn't find any solution or person who had to deal with the same situation. In my project, one value type (No matter which one) always seems to change it's value after a specific amount of time (time varies with type and there seems to be no reference in the project that changes it unexpectedly). Could it be because of the GC? Or am i doing something wrong code wise?
20 Replies
you must have a bug in your code. we probably need to see your code
Here's the zipped version
please use GitHub or $paste
If your code is too long, you can post to https://paste.mod.gg/ and copy the link into chat for others to see your shared code!
The problem seems to be originating from the transform struct in the transforming file
https://github.com/32BitFelix/FinderEngine here's the link to the repo
GitHub
GitHub - 32BitFelix/FinderEngine: Engine written in C# with the aid...
Engine written in C# with the aid of opentk. Contribute to 32BitFelix/FinderEngine development by creating an account on GitHub.
The error seems to be originating from the transform class from the Utility/Transforming.cs file
first off.. you need to set your resources to copy if newer
You code will fail if those files are not copied to your build directory
so you just need to update that setting to make sure the files get copied when you build
Okay
But the error appeared when i runned it directly with the "dotnet run" command
No pre built version was in use
even so, just change that setting. they should have that setting
Alright
Other than that, did you notice anything else?
still looking
Alright, found the problem
@ZP ░▒▓█├■̶˾̶͞■┤█▓▒░ I was having a "persistent" reference at another object to a pointer that was made out with the "fixed" operator from the transform struct. I now made it that the "persistent" reference is updated every update call. But thanks for into looking into it nonetheless and the feedback you gave me for the files
nice nice
Have you heard of Silk.NET before?
Just a little, why?
I personally startied usign that over OpenTK
https://github.com/dotnet/Silk.NET
I like it a bit better so far
Also there is https://github.com/terrafx/terrafx if you want low-level bindings rather than OpenTK and Silk's higher level wrappers
Holy god, that seems like THE binding for engine development in c#
Thanks for telling, I'll check these out
Was this issue resolved? If so, run
/close
- otherwise I will mark this as stale and this post will be archived until there is new activity.