VScripts and Portal 2
I would LIKE to have timer screens that you can pause and that will 'clock up' to the time that they countdown from.
Is this possible with scripts, if so, how would I go about this manual, brute force way of handling a timer?
Cheers.
Thanks.
They wouldn't have wasted the time integrating squirrel into the engine if it was just to "automate what you could do in hammer", they would have just added automation to what you can do in hammer.
Example,
I'm working on a portal 2 map that has physics objects you need to break.
The idea is to break them by dropping them from a high location, but you need to know if you are holding the object high enough for it to break (or take damage).
I thought, hey, let's make lights that change color depending on how high you're holding it depending on how much health the object has left!
IMPOSSIBLE to do in hammer.
Possible with vscripts. (draw a traceline from the object straight down, check the distance to collision against the remaining health by approximating potential damage with square roots)
There are SOOO many awesome things you can do with vscripts (potentially)
unfortunately, they are basically undocumented, so the mappers are stuck figuring everything out with trial and error.
They let you do a lot of things, and that timer would certainly be possible. You'd need three overlays using those underground neon numbers, then use a script to count, split the number into digits, and fire an env_texturetoggle with the results.