etreit
Windows Defender trojan alert after publish
I’m afk but should be back home soon and can take a look, might be worth seeing if you can do an update, I think I remember something about a meterpreter detection that was having some false positives that was removed, but might still be on your machine. I can verify if that might be the case in a bit.
33 replies
❔ How would I implement a toroidal universe?
Because you are taking the remainder, even if, say,
column + 1
is outside the range of the board, it will "reset" the value, effectively "wrapping" it over to the other end. So if you were in a 10x10
grid (which means we will mod by 10), numbered 0-9
, and your column value is 9, then (column + 1) mod 10 = 10 mod 10 = 0
24 replies
❔ How would I implement a toroidal universe?
You could just check and see if
gameboard[(row - 1) % settings.defaultGridSize][(column + 1) % settings.defaultGridSize]
exists, and then increment the total (I think this is how you use modulo in c++, I'm not really a dev so please take any random code snippets with a grain of salt)24 replies
❔ How would I implement a toroidal universe?
Honestly, most of the time working in this sort of space makes code a bit simpler. You can reduce a lot of your checks because you don't ever need to worry about a "surrounding square" being out of bounds. So, for example, taking
24 replies
❔ How would I implement a toroidal universe?
Basically, if I'm understand correctly, the main thing you are trying to do is get the count of all live squares near a coordinate, including wrapping around to the other side of the board. The concepts behind modular arithmetic are pretty simple, you just keep counting and reset to 0 every time you hit, very similar to if you were counting on a clock which is the same as mod 12.
24 replies