[xNir] Security Cameras 
10 comments

This script allows you to place security cameras on the map.
These cameras have a lot of parameters which can be customized.
For instance, the starting rotation, the laser range and color,
the camera type and so on.
At the moment, the cameras just play an alarm sound if a player
walked into a camera laser.
You can also destroy these cameras !!







1. Download the archive
2. Extract the content of the archive into your cs2d root folder.
3. Edit the config file.

I want to add one default camera on de_dust
What I need it's the position in pixels of my camera.
Then the type of the camera:
camera.IDLE: a camera which doesn't move
camera.MOBILE: a camera which moves
Finally add these lines in the config file: <sys/lua/camera/cfg/config.cfg>
Code:
1
2
3
4
5
6
7
8
2
3
4
5
6
7
8
camera.Locations = {
["de_dust"] = {
{
pos = { 656, 2408 },
type = camera.MOBILE,
},
}
}
["de_dust"] = {
{
pos = { 656, 2408 },
type = camera.MOBILE,
},
}
}

If you don't see cameras restart the round first !
edited 3×, last 18.07.16 11:36:20 pm

Comments
10 comments



Log in!
You need to log in to be able to write comments!Log in

@
xNir: Yes, this.
and also camera radius. for example you set it's rot 90 and set the angle:
minus = -3,
plus = 22,

and also camera radius. for example you set it's rot 90 and set the angle:
minus = -3,
plus = 22,
@_T Yes, I know I'm bad on designing cool graphics stuff.
Actually, I'm rather a scripter than a designer.
@Mora_rus So, you mean cameras with differents sprites ?
May I'll implement this in the future.
Actually, I'm rather a scripter than a designer.
@Mora_rus So, you mean cameras with differents sprites ?
May I'll implement this in the future.

Maybe you have to add in the table with camera this:
so you can use image dir. as
image = "gfx/cam/camera1.png",
so you can use image dir. as
img[id]=image(camera.Locations[i].image..""
(or however it is.) 


