Prison Architect

Prison Architect

Automatic CCTV Guard Response
43 Comments
✚ I TomBeryman 26 Mar @ 2:37pm 
alr, thanks.
Ater  [author] 24 Mar @ 5:26pm 
@TomBeryman Sadly, that's a bug I could not figure how to solve. Sorry :/

The modding API for PA is very basic, and there's no "move there but stop if anything bad happens" command that I could find. Only this "go there and ignore everything" that you see the mod use.

Obviously the game has a "move and look" function, because you don't see guards just ignoring misbehaving prisoners in vanilla, like you did with the mod. That said, that function is likely C++ only, and not exposed to the Lua API :(
✚ I TomBeryman 12 Mar @ 8:03am 
@Ater Is this a bug? When guards respond to a misbehaving prisoners then they just go to the room batons out, but when the prisoner is next to them running away they just ignore him.
Ater  [author] 30 Jan @ 11:48am 
30 (seconds) / 4 (game speed) = 7.5 (seconds between camera checks), but I guess those random variations on the update timers for the different cameras made the lag more "spread out", hitting at roughly 0.5 a second like you mentioned.

I purposely made it spread out to make the lag spikes minimal and hopefully unnoticeable, as making it just a concentrated big spike really sucked to play with.
Ater  [author] 30 Jan @ 11:39am 
@Lioncat6 I think it might be lagging every half a second because each camera, running the script separately, checks whether there's a prisoner misbehaving every 30 seconds at normal speed. (With a little random variance to reduce lag spikes)

So the more cameras you have and the faster the speed, the more they check.

When I was originally making the mod, I really wanted to make it event-based, as in, only if a prisoner starts misbehaving, have the "world" check if a camera caught sight of it.

But sadly, I had to make them "timed" like that, because the modding API is quite limited. :/
And for some reason you HAVE to have scripts running inside objects physically on the map, instead of just running in the background.

I was experimenting with update timers greater than 30 seconds, but that's usually how long it takes for a prisoner to destroy and open a cell door enough to escape, so it made the mod unreliable for what I wanted to achieve. So I capped it at 30 seconds.
Lioncat6 29 Jan @ 6:36pm 
Yeah, PA mods are very much just behavior or texture modifications to the game... so not much going with any deeper modifications like that unless of course the files could be decrypted and someone was willing to put the effort in.
Sean Diaz 29 Jan @ 8:16am 
yeah and very sadly, that is not something modders could try to fix either. not untill PA2 released, and we might be able to beg them into releasing a open version modkit that lets us mod the games engine for pa1. but they would have to decrypt the game fully so modders with knownledge could attempt fixes and maybe getting it to run on more threads.
Lioncat6 28 Jan @ 3:41pm 
Yeah, the game being single threaded makes a lot of sense considering my PC being heavily CPU bottle-necked...
Sean Diaz 28 Jan @ 5:33am 
do keep in mind, even if you got a powerfull CPU, the game is build to ONLY run on a SINGLE CORE..... so it never will be able to ultiize the CPU really which is partly where the games problems come from. sadly by adding more content your only going to strain the game more and more, esp as these new devs really liked to mess it up even more and break more things which has caused larger prisons to be near impossible. and i find -500 folk too little for having true fun sense. lol game feels so dull after a while with just so little to observe.
Lioncat6 27 Jan @ 8:31pm 
Compared to that, not that large... ~600. With the mod running though, whenever the game is on 4x speed, the game stutters every half second or so. Anyways: here's a video of the stuttering I'm talking about. https://imgur.com/a/DlEi3rk
Sean Diaz 26 Jan @ 9:26pm 
Define Large prisons?

i have a 8x expanded map with 1500 staff and 1600 prisoners... bad fps too but deff not caused by this mod. the game is VERY POORLY optimized as the new purchasing developer only screwed it up more.
Lioncat6 26 Jan @ 3:24pm 
Seems to work a little better now, but still slightly buggy... it causes the game to stutter with a large prison for whatever reason, not unplayable but rather annoying
Lioncat6 26 Jan @ 3:12pm 
@Ater Thank you! :tobdog:
Ater  [author] 26 Jan @ 8:29am 
@Anakin177 @Ozoneraxi @Lone Wolf
I think it's fixed now!

If it doesn't work though, please let me know in the comments.
Ater  [author] 26 Jan @ 7:46am 
I'm trying to fix it.
Hopefully it will work once I'm finished.
I'm trying to use the standard Steam Workshop, as opposed to that manual link stuff.
freakyfeathers 12 Jan @ 11:08am 
is the link still broke?
CyberNeo 29 Jun, 2024 @ 9:47am 
@Ater
You know that you somehow flipped the manual download link.
Reverie 4 Jun, 2024 @ 2:22am 
It feels like this should already be a feature in the game and should not require mods besides that this is a awesome mod:steamthis:
LinK 27 Mar, 2024 @ 4:38am 
this is great!thanks for your mod!:steamthumbsup:
and this is Chinese translation about this mod
当囚犯开始行为不端并被闭路电视发现时,自动呼叫附近可用的警卫。

当你玩看守模式或当你只是想自动无线电呼叫备份时很有用。

由于某些原因,Steam工作室打破了这个mod,所以它没有下载。
你可以在这里手动下载:
Worldo 12 Jan, 2024 @ 5:53pm 
I can confirm that this mod works. It is most noticeable when a large group of prisoners start causing trouble in front of CCTV, where one guard will be pulled for each prisoner.
giggitygames 24 Dec, 2023 @ 9:39pm 
this is great :steamthumbsup:
Anakin1773 23 Dec, 2023 @ 4:38pm 
You can use this website to reverse the link to something human-readable: https://www.textreverse.com/
Ater  [author] 22 Dec, 2023 @ 11:50am 
For some reason the Steam Workshop broke for this mod so it doesn't download.
You can manually download it here:
elif/piz.esnopseR_drauG_VTCC_citamotuA/5g2jo9q8bb83t57/elif/moc.erifaidem.www/:sptth (please reverse the link)
To install, unzip "Automatic CCTV Guard Response" to C:\Users\YOUR_USER_NAME_GOES_HERE\AppData\Local\Introversion\Prison Architect\mods
小猪贝 22 Dec, 2023 @ 12:41am 
good:steamthumbsup:
DrGoldenEye 17 Dec, 2023 @ 7:53am 
yep
Lone Wolf 14 Dec, 2023 @ 7:00pm 
@Ozoneraxi: Good catch. I'm glad I always read comment's before subscribing.:104:
Ozoneraxi 14 Dec, 2023 @ 12:45am 
@Ater It appears something went wrong during your mod upload, the mod size is 0MB.
Anakin1773 9 Dec, 2023 @ 3:29pm 
Also, would you consider creating a version that draws guards from 100 or even 200 blocks away? I ask because I am unsure if this mod is actually working. So I wish for the effect to be exaggerated to see it in action.
Anakin1773 8 Dec, 2023 @ 8:06pm 
Why does this mod have no data? Is this intentional?
Ater  [author] 25 Oct, 2023 @ 6:34pm 
@Robot20907 They only come it if they're close enough to the incident.

This mod pulls guards up to 50 blocks away to respond, if needed. But prioritizes the closest ones.
Ater  [author] 25 Oct, 2023 @ 6:31pm 
Just a heads up for people wondering about the mod's development.
I've quite busy at work so development took a bit of a halt.

BUT I'll get back to it once things at work cool down.
Cheers for all the support
Robot20907 25 Oct, 2023 @ 1:40am 
dont guards already reply to cctv spotting misbehaving prisoners if cctv improvement is researched in the base game? is there a difference between waht the base game and what this mod does?
Bosh 23 Oct, 2023 @ 2:50am 
what do you mean this wasn't in the base game
Robot20907 21 Oct, 2023 @ 10:39am 
hello, has ozoneraxis idea for the cctv cone been implemented ytet?
bentenbenneb 29 Sep, 2023 @ 6:54am 
how can i get more then 8 cctv to one monitor? with or without modding or edited the game files
Ater  [author] 24 Sep, 2023 @ 12:35pm 
Cheers! @The swedish viper
The swedish viper 22 Sep, 2023 @ 5:11pm 
Well done, this is what CCTV needed. I can´t believe this isn´t in the base game.
Ater  [author] 22 Sep, 2023 @ 10:59am 
Oh that's a really good idea @Ozoneraxi. I'll try to incorporate the prisoner's position and camera's orientation into it.
Cheers!
Ozoneraxi 22 Sep, 2023 @ 9:47am 
Here is a suggestion regarding the disclaimer: You could "somewhat check if the inmate is in a cone" by first checking the camera orientation (Or.x and Or.y) then depending on each case you would compare the coordinates of the inmate relative to the camera coordinates.

E.g. If the camera is facing eastwards (specific Or.x / Or.y combination) then it should only call guards if the inmate's Pos.x is higher than the camera's (higher Pos.x value means more eastward on the map). Combine this with the distance check and you basically get a CCTV that stops detecting inmates behind it.
Ater  [author] 21 Sep, 2023 @ 1:48pm 
Hey @Sean Diaz, sorry for the delay, I was off on a business trip.
I looked into the icon popups you mentioned, but I couldn't find any way to modify them with mods atm.

Maybe I looked on the wrongs places though.
If another mod that modifies these popups ever shows up, I'd like to have a look at their code to figure out if it's possible to remove them/make them disappear faster.
Feel free to DM me if you notice a mod like that gets added on the workshop.
Ater  [author] 21 Sep, 2023 @ 1:48pm 
Glad to have helped!
Yeah I wish Warden Mode was toggleable too haha
FkYoSht 17 Sep, 2023 @ 8:12pm 
This is epic since i figured out YOU CANT TURN OFF WARDEN MODE. Thx for this lol
Sean Diaz 17 Sep, 2023 @ 12:18am 
super good... :D thank you.

could you perhaps try to somehow BREAK those pesky staff icons that lock you onto the whatever it is? like helicopters and such are pissing me the f** off with constantly locking me onto the shopper while building D: