Merge pull request #9939 from Miauw62/EyeAye

Several further tweaks to AI camera balance.
This commit is contained in:
phil235
2015-06-17 19:58:06 +02:00
4 changed files with 28 additions and 8 deletions
+11 -4
View File
@@ -73,6 +73,7 @@
var/thisemp = emped //Take note of which EMP this proc is for
spawn(900)
if(loc) //qdel limbo
triggerCameraAlarm() //camera alarm triggers even if multiple EMPs are in effect.
if(emped == thisemp) //Only fix it if the camera hasn't been EMP'd again
network = previous_network
icon_state = initial(icon_state)
@@ -80,7 +81,6 @@
if(can_use())
cameranet.addCamera(src)
emped = 0 //Resets the consecutive EMP count
triggerCameraAlarm()
spawn(100)
cancelCameraAlarm()
for(var/mob/O in mob_list)
@@ -226,11 +226,13 @@
L.laser_act(src, user)
else
if(W.force > 10) //fairly simplistic, but will do for now.
if(W.force >= 10) //fairly simplistic, but will do for now.
user.changeNext_move(CLICK_CD_MELEE)
visible_message("<span class='warning'>[user] hits [src] with [W]!</span>", "<span class='warning'>You hit [src] with [W]!</span>")
health = max(0, health - W.force)
user.do_attack_animation(src)
if(!health && status)
triggerCameraAlarm()
deactivate(user, 1)
return
@@ -244,7 +246,6 @@
else
visible_message("<span class='danger'>\The [src] deactivates!</span>")
icon_state = "[initial(icon_state)]1"
else
if(user)
visible_message("<span class='danger'>[user] reactivates [src]!</span>")
@@ -256,6 +257,7 @@
spawn(100)
cancelCameraAlarm()
playsound(src.loc, 'sound/items/Wirecutter.ogg', 100, 1)
cameranet.updateChunk(x, y, z)
// now disconnect anyone using the camera
//Apparently, this will disconnect anyone even if the camera was re-activated.
@@ -271,7 +273,6 @@
for(var/mob/living/silicon/S in mob_list)
S.triggerAlarm("Camera", get_area(src), list(src), src)
/obj/machinery/camera/proc/cancelCameraAlarm()
alarm_on = 0
for(var/mob/living/silicon/S in mob_list)
@@ -345,6 +346,12 @@
busy = 0
return 0
/obj/machinery/camera/bullet_act(var/obj/item/projectile/proj)
if(proj.damage_type == BRUTE)
health = max(0, health - proj.damage)
if(!health && status)
triggerCameraAlarm()
deactivate(null, 1)
/obj/machinery/camera/portable //Cameras which are placed inside of things, such as helmets.
var/turf/prev_turf
+7 -4
View File
@@ -105,19 +105,22 @@
var/cameraticks = 0
spawn(0)
while (U.cameraFollow == target)
if (U.cameraFollow == null)
while(U.cameraFollow == target)
if(U.cameraFollow == null)
return
if (!target.can_track(usr))
if(!target.can_track(usr))
U.tracking = 1
U << "<span class='warning'>Target is not near any active cameras.</span>"
if(!cameraticks)
U << "<span class='warning'>Target is not near any active cameras. Attempting to reacquire...</span>"
cameraticks++
if(cameraticks > 9)
U.cameraFollow = null
U << "<span class='warning'>Unable to reacquire, cancelling track...</span>"
tracking = 0
return
else
sleep(10)
continue
else
+3
View File
@@ -85,3 +85,6 @@ You can use . or # instead of : for radio channels. Building this habit reduces
While pulling something, clicking on a tile with an empty hand will move it to that tile. No more getting stuck in maint while dragging something!
Things that override clicks like decks of cards or paper bins can still be picked up by dragging them to your character. Equipped things that override click can be unequipped by dragging it to an empty hand.
In the job selection menu, from the lobby, you can use right click on the "Low/Medium/High" priority button to make it cycle backwards.
If you stay out of camera range for 10 seconds, the AI's track on you will break.
You can shoot cameras with bullets to disable them remotely.
Disabling a camera with wirecutters will not cause a camera alarm, but bludgeoning it will.
+7
View File
@@ -0,0 +1,7 @@
author: Miauw
delete-after: True
changes:
- tweak: "Bullets can now damage cameras."
- tweak: "Camera alarms now trigger 90 seconds after the first EMP pulse, instead of when all EMP pulses run out."
- tweak: "Makes the force required to damage cameras greater than or equal to ten instead of greater than ten."
- tweak: "Camera alarms now trigger when cameras are disabled with brute force or bullets."