Years ago for educational purposes I decided to venture down understanding how easy/difficult it was to create a hack for Counterstrike. After just a few hours of watching YouTube tutorials and translating what I could grasp from C/C# into JavaScript (the only language I knew at the time), I had a working Node.js executable that edited memory offsets (using data from hazedumper[1]), letting me see enemies through wal…
The thing is, VAC doesn't immediately ban you. Or anyone else. It's looking for suspicious patterns across hundreds if not thousands of players and collecting evidence over weeks if not months to make sure they got relatively low false-positive rates and don't end up banning people for a Windows update gone wrong... and additionally, it raises the iteration time for cheat developers as well, and that's the true point. Show cheaters immediately that they're spotted and the only thing you enter is an immediate arms race.
Your way of writing a cheat was probably detected but since no one else used it, VAC didn't trigger.