Updates Intents

This commit is contained in:
Sam
2017-06-10 09:43:36 +01:00
parent c1cc319f62
commit 4d57fff5c9
94 changed files with 200 additions and 200 deletions
@@ -15,7 +15,7 @@ In all, this is a lot like the monkey code. /N
return
switch(M.a_intent)
if(I_HELP)
if(INTENT_HELP)
AdjustSleeping(-5)
resting = 0
AdjustParalysis(-3)
@@ -23,7 +23,7 @@ In all, this is a lot like the monkey code. /N
AdjustWeakened(-3)
visible_message("<span class='notice'>[M.name] nuzzles [src] trying to wake it up!</span>")
if(I_GRAB)
if(INTENT_GRAB)
grabbedby(M)
return 1
@@ -50,11 +50,11 @@ In all, this is a lot like the monkey code. /N
return 0 //this is horrible but 100% necessary
switch(M.a_intent)
if(I_HELP)
if(INTENT_HELP)
help_shake_act(M)
if(I_GRAB)
if(INTENT_GRAB)
grabbedby(M)
if(I_HARM, I_DISARM)
if(INTENT_HARM, INTENT_DISARM)
return 1
return 0
@@ -160,13 +160,13 @@
switch(M.a_intent)
if(I_HELP)
if(INTENT_HELP)
help_shake_act(M)
if(I_GRAB)
if(INTENT_GRAB)
grabbedby(M)
if(I_HARM)
if(INTENT_HARM)
M.do_attack_animation(src)
var/damage = rand(1, 9)
if(prob(90))
@@ -191,7 +191,7 @@
playsound(loc, 'sound/weapons/punchmiss.ogg', 25, 1, -1)
visible_message("<span class='danger'>[M] has attempted to punch [src]!</span>")
if(I_DISARM)
if(INTENT_DISARM)
if(!lying)
if(prob(5))//Very small chance to push an alien down.
Paralyse(2)
@@ -127,10 +127,10 @@
switch(M.a_intent)
if(I_HELP)
if(INTENT_HELP)
help_shake_act(M)
if(I_GRAB)
if(INTENT_GRAB)
grabbedby(M)
else
@@ -20,7 +20,7 @@
/mob/living/carbon/attackby(obj/item/I, mob/user, params)
if(lying)
if(surgeries.len)
if(user != src && user.a_intent == I_HELP)
if(user != src && user.a_intent == INTENT_HELP)
for(var/datum/surgery/S in surgeries)
if(S.next_step(user, src))
return 1
@@ -335,7 +335,7 @@
/mob/living/carbon/human/attack_larva(mob/living/carbon/alien/larva/L as mob)
switch(L.a_intent)
if(I_HELP)
if(INTENT_HELP)
visible_message("<span class='notice'>[L] rubs its head against [src].</span>")
@@ -4,13 +4,13 @@
return 0
switch(M.a_intent)
if(I_HELP)
if(INTENT_HELP)
visible_message("<span class='notice'>[M] caresses [src] with its scythe like arm.</span>")
if(I_GRAB)
if(INTENT_GRAB)
grabbedby(M)
if(I_HARM)
if(INTENT_HARM)
M.do_attack_animation(src)
if(w_uniform)
w_uniform.add_fingerprint(M)
@@ -33,7 +33,7 @@
apply_effect(4, WEAKEN, armor_block)
updatehealth()
if(I_DISARM)
if(INTENT_DISARM)
M.do_attack_animation(src)
if(prob(80))
var/obj/item/organ/external/affecting = get_organ(ran_zone(M.zone_sel.selecting))
@@ -18,7 +18,7 @@
..()
if((M != src) && M.a_intent != I_HELP && check_shields(0, M.name, attack_type = UNARMED_ATTACK))
if((M != src) && M.a_intent != INTENT_HELP && check_shields(0, M.name, attack_type = UNARMED_ATTACK))
add_logs(M, src, "attempted to touch")
visible_message("<span class='warning'>[M] attempted to touch [src]!</span>")
return 0
@@ -53,7 +53,7 @@
species.handle_attack_hand(src,M)
switch(M.a_intent)
if(I_HELP)
if(INTENT_HELP)
if(attacker_style && attacker_style.help_act(H, src))//adminfu only...
return 1
if(can_operate(src))
@@ -99,14 +99,14 @@
else
to_chat(M, "<span class='danger'>You need to stay still while performing CPR!</span>")
if(I_GRAB)
if(INTENT_GRAB)
if(attacker_style && attacker_style.grab_act(H, src))
return 1
else
src.grabbedby(M)
return 1
if(I_HARM)
if(INTENT_HARM)
//Vampire code
if(M.mind && M.mind.vampire && (M.mind in ticker.mode.vampires) && !M.mind.vampire.draining && M.zone_sel && M.zone_sel.selecting == "head" && src != M)
if(species && species.flags & NO_BLOOD)//why this hell were we never checkinf for this?
@@ -168,7 +168,7 @@
forcesay(hit_appends)
if(I_DISARM)
if(INTENT_DISARM)
if(attacker_style && attacker_style.disarm_act(H, src))
return 1
else
@@ -191,7 +191,7 @@ emp_act
/mob/living/carbon/human/proc/attacked_by(var/obj/item/I, var/mob/living/user, var/def_zone)
if(!I || !user) return 0
if((istype(I, /obj/item/weapon/kitchen/knife/butcher/meatcleaver) || istype(I, /obj/item/weapon/twohanded/chainsaw)) && src.stat == DEAD && user.a_intent == I_HARM)
if((istype(I, /obj/item/weapon/kitchen/knife/butcher/meatcleaver) || istype(I, /obj/item/weapon/twohanded/chainsaw)) && src.stat == DEAD && user.a_intent == INTENT_HARM)
var/obj/item/weapon/reagent_containers/food/snacks/meat/human/newmeat = new /obj/item/weapon/reagent_containers/food/snacks/meat/human(get_turf(src.loc))
newmeat.name = src.real_name + newmeat.name
newmeat.subjectname = src.real_name
@@ -378,7 +378,7 @@ emp_act
if(penetrated_dam) SS.create_breaches(damtype, penetrated_dam)
/mob/living/carbon/human/mech_melee_attack(obj/mecha/M)
if(M.occupant.a_intent == I_HARM)
if(M.occupant.a_intent == INTENT_HARM)
if(M.damtype == "brute")
step_away(src,M,15)
var/obj/item/organ/external/affecting = get_organ(pick("chest", "chest", "chest", "head"))
@@ -638,7 +638,7 @@
if(canmove)
if((graytide || (TRAITS & TRAIT_MEAN)) || retal)
interest += targetInterestShift
a_intent = I_HARM
a_intent = INTENT_HARM
zone_sel.selecting = pick("chest","r_leg","l_leg","r_arm","l_arm","head")
doing |= SNPC_FIGHTING
if(retal)
@@ -746,7 +746,7 @@
tryWalk(TARGET)
else
if(Adjacent(TARGET))
a_intent = pick(I_DISARM, I_HARM)
a_intent = pick(INTENT_DISARM, INTENT_HARM)
M.attack_hand(src)
timeout++
else if(timeout >= 10 || !(targetRange(M) > 14))
@@ -431,7 +431,7 @@
var/mob/living/M = target
if(istype(M))
if(health > 0)
if(M.a_intent == I_HELP && !incapacitated())
if(M.a_intent == INTENT_HELP && !incapacitated())
chatter()
if(istype(target, /mob/living/carbon) && !retal && prob(SNPC_FUZZY_CHANCE_LOW))
var/mob/living/carbon/C = target
@@ -439,7 +439,7 @@
tryWalk(target)
else
C.help_shake_act(src)
if(M.a_intent == I_HARM)
if(M.a_intent == INTENT_HARM)
retal = 1
retal_target = target
@@ -658,7 +658,7 @@
if(grabbed_by.len > 0)
for(var/obj/item/weapon/grab/G in grabbed_by)
if(Adjacent(G))
a_intent = I_DISARM
a_intent = INTENT_DISARM
G.assailant.attack_hand(src)
inactivity_period = 10
@@ -58,7 +58,7 @@
/datum/species/wryn/handle_attack_hand(var/mob/living/carbon/human/H, var/mob/living/carbon/human/M)
var/obj/item/organ/external/head/head_organ = H.get_organ("head")
if(M.a_intent == I_HARM)
if(M.a_intent == INTENT_HARM)
if(H.handcuffed)
if(!H.get_int_organ(/obj/item/organ/internal/wryn/hivenode)) return
var/turf/p_loc = M.loc
@@ -241,7 +241,7 @@
switch(L.a_intent)
if(I_HELP)
if(INTENT_HELP)
visible_message("<span class='notice'>[L] rubs its head against [src].</span>")
@@ -322,7 +322,7 @@
return
else
if(stat == DEAD && surgeries.len)
if(M.a_intent == I_HELP)
if(M.a_intent == INTENT_HELP)
for(var/datum/surgery/S in surgeries)
if(S.next_step(M, src))
return 1
@@ -343,10 +343,10 @@
switch(M.a_intent)
if(I_HELP)
if(INTENT_HELP)
help_shake_act(M)
if(I_GRAB)
if(INTENT_GRAB)
grabbedby(M)
else
@@ -393,10 +393,10 @@
return
switch(M.a_intent)
if(I_HELP)
if(INTENT_HELP)
visible_message("<span class='notice'>[M] caresses [src] with its scythe like arm.</span>")
if(I_HARM)
if(INTENT_HARM)
M.do_attack_animation(src)
if(prob(95))
attacked += 10
@@ -416,10 +416,10 @@
visible_message("<span class='danger'>[M] has attempted to lunge at [name]!</span>", \
"<span class='userdanger'>[M] has attempted to lunge at [name]!</span>")
if(I_GRAB)
if(INTENT_GRAB)
grabbedby(M)
if(I_DISARM)
if(INTENT_DISARM)
M.do_attack_animation(src)
playsound(loc, 'sound/weapons/pierce.ogg', 25, 1, -1)
var/damage = 5
@@ -460,7 +460,7 @@
/mob/living/carbon/slime/attackby(obj/item/W, mob/user, params)
if(stat == DEAD && surgeries.len)
if(user.a_intent == I_HELP)
if(user.a_intent == INTENT_HELP)
for(var/datum/surgery/S in surgeries)
if(S.next_step(user, src))
return 1
+3 -3
View File
@@ -60,10 +60,10 @@
if(!M.buckled && !M.has_buckled_mobs())
var/mob_swap
//the puller can always swap with it's victim if on grab intent
if(M.pulledby == src && a_intent == I_GRAB)
if(M.pulledby == src && a_intent == INTENT_GRAB)
mob_swap = 1
//restrained people act if they were on 'help' intent to prevent a person being pulled from being seperated from their puller
else if((M.restrained() || M.a_intent == I_HELP) && (restrained() || a_intent == I_HELP))
else if((M.restrained() || M.a_intent == INTENT_HELP) && (restrained() || a_intent == INTENT_HELP))
mob_swap = 1
if(mob_swap)
//switch our position with M
@@ -176,7 +176,7 @@
return 0
var/obj/item/hand_item = get_active_hand()
if(istype(hand_item, /obj/item/weapon/gun) && A != hand_item)
if(a_intent == I_HELP || !ismob(A))
if(a_intent == INTENT_HELP || !ismob(A))
visible_message("<b>[src]</b> points to [A] with [hand_item]")
return 1
A.visible_message("<span class='danger'>[src] points [hand_item] at [A]!</span>",
+1 -1
View File
@@ -108,7 +108,7 @@
/mob/living/mech_melee_attack(obj/mecha/M)
if(M.occupant.a_intent == I_HARM)
if(M.occupant.a_intent == INTENT_HARM)
if(M.damtype == "brute")
step_away(src,M,15)
switch(M.damtype)
+1 -1
View File
@@ -677,7 +677,7 @@ var/list/ai_verbs_default = list(
switch(M.a_intent)
if(I_HELP)
if(INTENT_HELP)
visible_message("<span class='notice'>[M] caresses [src]'s plating with its scythe like arm.</span>")
else //harm
+2 -2
View File
@@ -246,7 +246,7 @@
switch(M.a_intent)
if(I_HELP)
if(INTENT_HELP)
for(var/mob/O in viewers(src, null))
if((O.client && !( O.blinded )))
O.show_message(text("<span class='notice'>[M] caresses [src]'s casing with its scythe like arm.</span>"), 1)
@@ -508,7 +508,7 @@
/mob/living/silicon/pai/attack_hand(mob/user as mob)
if(stat == DEAD)
return
if(user.a_intent == I_HELP)
if(user.a_intent == INTENT_HELP)
user.visible_message("<span class='notice'>[user] pets [src].</span>")
playsound(loc, 'sound/weapons/thudswoosh.ogg', 50, 1, -1)
else
@@ -44,7 +44,7 @@
//Actual picking-up event.
/mob/living/silicon/robot/drone/attack_hand(mob/living/carbon/human/M as mob)
if(M.a_intent == I_HELP)
if(M.a_intent == INTENT_HELP)
get_scooped(M)
..()
@@ -575,7 +575,7 @@ var/list/robot_verbs_default = list(
return
if(istype(W, /obj/item/weapon/weldingtool) && user.a_intent == I_HELP)
if(istype(W, /obj/item/weapon/weldingtool) && user.a_intent == INTENT_HELP)
if(W == module_active)
return
if(!getBruteLoss())
@@ -594,7 +594,7 @@ var/list/robot_verbs_default = list(
return
else if(istype(W, /obj/item/stack/cable_coil) && user.a_intent == I_HELP && (wiresexposed || istype(src,/mob/living/silicon/robot/drone)))
else if(istype(W, /obj/item/stack/cable_coil) && user.a_intent == INTENT_HELP && (wiresexposed || istype(src,/mob/living/silicon/robot/drone)))
if(!getFireLoss())
to_chat(user, "<span class='notice'>Nothing to fix!</span>")
return
@@ -818,15 +818,15 @@ var/list/robot_verbs_default = list(
switch(M.a_intent)
if(I_HELP)
if(INTENT_HELP)
for(var/mob/O in viewers(src, null))
if((O.client && !( O.blinded )))
O.show_message(text("<span class='notice'>[M] caresses [src]'s plating with its scythe like arm.</span>"), 1)
if(I_GRAB)
if(INTENT_GRAB)
grabbedby(M)
if(I_HARM)
if(INTENT_HARM)
M.do_attack_animation(src)
var/damage = rand(10, 20)
if(prob(90))
@@ -842,7 +842,7 @@ var/list/robot_verbs_default = list(
visible_message("<span class='danger'>[M] took a swipe at [src]!</span>", \
"<span class='userdanger'>[M] took a swipe at [src]!</span>")
if(I_DISARM)
if(INTENT_DISARM)
if(!(lying))
M.do_attack_animation(src)
if(prob(85))
@@ -923,7 +923,7 @@ var/list/robot_verbs_default = list(
diag_hud_set_borgcell()
if(!opened && (!istype(user, /mob/living/silicon)))
if(user.a_intent == I_HELP)
if(user.a_intent == INTENT_HELP)
user.visible_message("<span class='notice'>[user] pets [src]!</span>", \
"<span class='notice'>You pet [src]!</span>")
@@ -256,7 +256,7 @@
new /obj/effect/decal/cleanable/blood/oil(loc)
/mob/living/simple_animal/bot/attack_hand(mob/living/carbon/human/H)
if(H.a_intent == I_HELP)
if(H.a_intent == INTENT_HELP)
interact(H)
else
return ..()
@@ -329,7 +329,7 @@
ejectpai(user)
else
user.changeNext_move(CLICK_CD_MELEE)
if(istype(W, /obj/item/weapon/weldingtool) && user.a_intent != I_HARM)
if(istype(W, /obj/item/weapon/weldingtool) && user.a_intent != INTENT_HARM)
if(health >= maxHealth)
to_chat(user, "<span class='warning'>[src] does not need a repair!</span>")
return
@@ -161,13 +161,13 @@ Auto Patrol[]"},
mode = BOT_HUNT
/mob/living/simple_animal/bot/ed209/attack_hand(mob/living/carbon/human/H)
if(H.a_intent == I_HARM)
if(H.a_intent == INTENT_HARM)
retaliate(H)
return ..()
/mob/living/simple_animal/bot/ed209/attackby(obj/item/weapon/W, mob/user, params)
..()
if(istype(W, /obj/item/weapon/weldingtool) && user.a_intent != I_HARM) // Any intent but harm will heal, so we shouldn't get angry.
if(istype(W, /obj/item/weapon/weldingtool) && user.a_intent != INTENT_HARM) // Any intent but harm will heal, so we shouldn't get angry.
return
if(!istype(W, /obj/item/weapon/screwdriver) && (!target)) // Added check for welding tool to fix #2432. Welding tool behavior is handled in superclass.
if(W.force && W.damtype != STAMINA)//If force is non-zero and damage type isn't stamina.
@@ -18,7 +18,7 @@
health = 50
maxHealth = 50
damage_coeff = list(BRUTE = 0.5, BURN = 0.7, TOX = 0, CLONE = 0, STAMINA = 0, OXY = 0)
a_intent = I_HARM //No swapping
a_intent = INTENT_HARM //No swapping
buckle_lying = 0
mob_size = MOB_SIZE_LARGE
radio_channel = "Supply"
@@ -173,13 +173,13 @@ Auto Patrol: []"},
mode = BOT_HUNT
/mob/living/simple_animal/bot/secbot/attack_hand(mob/living/carbon/human/H)
if(H.a_intent == I_HARM)
if(H.a_intent == INTENT_HARM)
retaliate(H)
return ..()
/mob/living/simple_animal/bot/secbot/attackby(obj/item/weapon/W, mob/user, params)
..()
if(istype(W, /obj/item/weapon/weldingtool) && user.a_intent != I_HARM) // Any intent but harm will heal, so we shouldn't get angry.
if(istype(W, /obj/item/weapon/weldingtool) && user.a_intent != INTENT_HARM) // Any intent but harm will heal, so we shouldn't get angry.
return
if(!istype(W, /obj/item/weapon/screwdriver) && (W.force) && (!target) && (W.damtype != STAMINA) ) // Added check for welding tool to fix #2432. Welding tool behavior is handled in superclass.
retaliate(user)
@@ -10,7 +10,7 @@
response_harm = "punches"
icon_dead = "shade_dead"
speed = 0
a_intent = I_HARM
a_intent = INTENT_HARM
stop_automated_movement = 1
status_flags = CANPUSH
attack_sound = 'sound/weapons/punch1.ogg'
@@ -557,8 +557,8 @@
/mob/living/simple_animal/pet/corgi/attack_hand(mob/living/carbon/human/M)
. = ..()
switch(M.a_intent)
if(I_HELP) wuv(1,M)
if(I_HARM) wuv(-1,M)
if(INTENT_HELP) wuv(1,M)
if(INTENT_HARM) wuv(-1,M)
/mob/living/simple_animal/pet/corgi/proc/wuv(change, mob/M)
if(change)
@@ -51,7 +51,7 @@
/mob/living/simple_animal/diona/attack_hand(mob/living/carbon/human/M)
//Let people pick the little buggers up.
if(M.a_intent == I_HELP)
if(M.a_intent == INTENT_HELP)
if(M.species && M.species.name == "Diona")
to_chat(M, "You feel your being twine with that of [src] as it merges with your biomass.")
to_chat(src, "You feel your being twine with that of [M] as you merge with its biomass.")
@@ -136,7 +136,7 @@
milk_content = min(50, milk_content+rand(5, 10))
/mob/living/simple_animal/cow/attack_hand(mob/living/carbon/M as mob)
if(!stat && M.a_intent == I_DISARM && icon_state != icon_dead)
if(!stat && M.a_intent == INTENT_DISARM && icon_state != icon_dead)
M.visible_message("<span class='warning'>[M] tips over [src].</span>","<span class='notice'>You tip over [src].</span>")
Weaken(30)
icon_state = icon_dead
@@ -77,7 +77,7 @@
client.time_died_as_mouse = world.time
/mob/living/simple_animal/mouse/attack_hand(mob/living/carbon/human/M as mob)
if(M.a_intent == I_HELP)
if(M.a_intent == INTENT_HELP)
get_scooped(M)
..()
@@ -18,7 +18,7 @@
melee_damage_upper = 25
attacktext = "slashes"
speak_emote = list("hisses")
a_intent = I_HARM
a_intent = INTENT_HARM
attack_sound = 'sound/weapons/bladeslice.ogg'
atmos_requirements = list("min_oxy" = 0, "max_oxy" = 0, "min_tox" = 0, "max_tox" = 0, "min_co2" = 0, "max_co2" = 0, "min_n2" = 0, "max_n2" = 0)
unsuitable_atmos_damage = 15
@@ -141,7 +141,7 @@
name = "lusty xenomorph maid"
melee_damage_lower = 0
melee_damage_upper = 0
a_intent = I_HELP
a_intent = INTENT_HELP
friendly = "caresses"
environment_smash = 0
icon_state = "maid"
@@ -7,7 +7,7 @@
icon_dead = "null"
melee_damage_lower = 5
melee_damage_upper = 5
a_intent = I_HARM
a_intent = INTENT_HARM
attacktext = "gores"
maxHealth = 100
health = 100
@@ -5,7 +5,7 @@
desc = "Attack the weak point for massive damage."
health = 1000
maxHealth = 1000
a_intent = I_HARM
a_intent = INTENT_HARM
sentience_type = SENTIENCE_BOSS
environment_smash = 3
luminosity = 3
@@ -19,7 +19,7 @@
melee_damage_upper = 0
attacktext = "barrels into"
attack_sound = 'sound/weapons/punch1.ogg'
a_intent = I_HELP
a_intent = INTENT_HELP
speak_emote = list("screeches")
throw_message = "sinks in slowly, before being pushed out of "
status_flags = CANPUSH
@@ -11,7 +11,7 @@
response_disarm = "shoves"
response_harm = "strikes"
status_flags = 0
a_intent = I_HARM
a_intent = INTENT_HARM
var/throw_message = "bounces off of"
var/icon_aggro = null // for swapping to when we get aggressive
see_in_dark = 8
@@ -68,7 +68,7 @@
melee_damage_lower = 12
melee_damage_upper = 12
attacktext = "bites into"
a_intent = I_HARM
a_intent = INTENT_HARM
speak_emote = list("chitters")
attack_sound = 'sound/weapons/bladeslice.ogg'
aggro_vision_range = 9
@@ -138,7 +138,7 @@
/mob/living/simple_animal/hostile/mushroom/attack_hand(mob/living/carbon/human/M as mob)
..()
if(M.a_intent == I_HARM)
if(M.a_intent == INTENT_HARM)
Bruise()
/mob/living/simple_animal/hostile/mushroom/hitby(atom/movable/AM)
@@ -13,7 +13,7 @@
speak = list("HONK", "Honk!", "Welcome to clown planet!")
emote_see = list("honks")
speak_chance = 1
a_intent = I_HARM
a_intent = INTENT_HARM
maxHealth = 75
health = 75
speed = 0
@@ -15,7 +15,7 @@
response_harm = "hits the"
speak = list("ALERT.","Hostile-ile-ile entities dee-twhoooo-wected.","Threat parameterszzzz- szzet.","Bring sub-sub-sub-systems uuuup to combat alert alpha-a-a.")
emote_see = list("beeps menacingly","whirrs threateningly","scans its immediate vicinity")
a_intent = I_HARM
a_intent = INTENT_HARM
stop_automated_movement_when_pulled = 0
health = 300
maxHealth = 300
@@ -18,7 +18,7 @@
melee_damage_upper = 15
attacktext = "punches"
attack_sound = 'sound/weapons/punch1.ogg'
a_intent = I_HARM
a_intent = INTENT_HARM
unsuitable_atmos_damage = 15
faction = list("russian")
status_flags = CANPUSH
@@ -28,7 +28,7 @@
maxbodytemp = 350
atmos_requirements = list("min_oxy" = 0, "max_oxy" = 0, "min_tox" = 0, "max_tox" = 0, "min_co2" = 0, "max_co2" = 0, "min_n2" = 0, "max_n2" = 0)
a_intent = I_HARM //so they don't get pushed around
a_intent = INTENT_HARM //so they don't get pushed around
environment_smash = 1
@@ -8,7 +8,7 @@
icon_living = "angel"
icon_dead = "angel"
gender = NEUTER
a_intent = I_HARM
a_intent = INTENT_HARM
response_help = "touches"
response_disarm = "pushes"
@@ -18,7 +18,7 @@
melee_damage_upper = 10
attacktext = "punches"
attack_sound = 'sound/weapons/punch1.ogg'
a_intent = I_HARM
a_intent = INTENT_HARM
unsuitable_atmos_damage = 15
faction = list("syndicate")
check_friendly_fire = 1
@@ -56,7 +56,7 @@
harm_intent_damage = 5
melee_damage_lower = 25
melee_damage_upper = 25
a_intent = I_HARM
a_intent = INTENT_HARM
attack_sound = 'sound/weapons/bladeslice.ogg'
atmos_requirements = list("min_oxy" = 0, "max_oxy" = 0, "min_tox" = 0, "max_tox" = 0, "min_co2" = 0, "max_co2" = 0, "min_n2" = 0, "max_n2" = 0)
unsuitable_atmos_damage = 0
@@ -304,12 +304,12 @@
switch(M.a_intent)
if(I_HELP)
if(INTENT_HELP)
if(health > 0)
visible_message("<span class='notice'> [M] [response_help] [src].</span>")
playsound(loc, 'sound/weapons/thudswoosh.ogg', 50, 1, -1)
if(I_GRAB)
if(INTENT_GRAB)
if(M == src || anchored)
return
if(!(status_flags & CANPUSH))
@@ -326,7 +326,7 @@
visible_message("<span class='warning'>[M] has grabbed [src] passively!</span>")
playsound(loc, 'sound/weapons/thudswoosh.ogg', 50, 1, -1)
if(I_HARM, I_DISARM)
if(INTENT_HARM, INTENT_DISARM)
M.do_attack_animation(src)
visible_message("<span class='danger'>[M] [response_harm] [src]!</span>")
playsound(loc, "punch", 25, 1, -1)
@@ -338,13 +338,13 @@
switch(M.a_intent)
if(I_HELP)
if(INTENT_HELP)
visible_message("<span class='notice'>[M] caresses [src] with its scythe like arm.</span>")
if(I_GRAB)
if(INTENT_GRAB)
grabbedby(M)
if(I_HARM, I_DISARM)
if(INTENT_HARM, INTENT_DISARM)
M.do_attack_animation(src)
var/damage = rand(15, 30)
visible_message("<span class='danger'>[M] has slashed at [src]!</span>", \
@@ -357,7 +357,7 @@
/mob/living/simple_animal/attack_larva(mob/living/carbon/alien/larva/L as mob)
switch(L.a_intent)
if(I_HELP)
if(INTENT_HELP)
visible_message("<span class='notice'>[L] rubs its head against [src].</span>")
@@ -12,7 +12,7 @@
status_flags = 0
anchored = 1
AIStatus = AI_OFF
a_intent = I_HARM
a_intent = INTENT_HARM
stop_automated_movement = 1
wander = 0
atmos_requirements = list("min_oxy" = 0, "max_oxy" = 0, "min_tox" = 0, "max_tox" = 0, "min_co2" = 0, "max_co2" = 5, "min_n2" = 0, "max_n2" = 0)
+1 -1
View File
@@ -75,7 +75,7 @@
var/overeatduration = 0 // How long this guy is overeating //Carbon
var/intent = null//Living
var/shakecamera = 0
var/a_intent = I_HELP//Living
var/a_intent = INTENT_HELP//Living
var/m_intent = "run"//Living
var/lastKnownIP = null
var/atom/movable/buckled = null//Living
+4 -4
View File
@@ -316,7 +316,7 @@
var/mob/living/carbon/human/affected = affecting
var/mob/living/carbon/human/attacker = assailant
switch(assailant.a_intent)
if(I_HELP)
if(INTENT_HELP)
/*if(force_down)
to_chat(assailant, "<span class='warning'>You no longer pin [affecting] to the ground.</span>")
force_down = 0
@@ -324,10 +324,10 @@
//This specific example would allow you to stop pinning people to the floor without moving away from them.
return
if(I_GRAB)
if(INTENT_GRAB)
return
if(I_HARM) //This checks that the user is on harm intent.
if(INTENT_HARM) //This checks that the user is on harm intent.
if(last_hit_zone == "head") //This checks the hitzone the user has selected. In this specific case, they have the head selected.
if(affecting.lying)
return
@@ -368,7 +368,7 @@
//This specific example would allow you to squish people's eyes with a GRAB_NECK.
if(I_DISARM) //This checks that the user is on disarm intent.
if(INTENT_DISARM) //This checks that the user is on disarm intent.
/* if(state < GRAB_AGGRESSIVE)
to_chat(assailant, "<span class='warning'>You require a better grab to do this.</span>")
return
+14 -14
View File
@@ -319,20 +319,20 @@ proc/muffledspeech(phrase)
return 0
//converts intent-strings into numbers and back
var/list/intents = list(I_HELP,I_DISARM,I_GRAB,I_HARM)
var/list/intents = list(INTENT_HELP,INTENT_DISARM,INTENT_GRAB,INTENT_HARM)
/proc/intent_numeric(argument)
if(istext(argument))
switch(argument)
if(I_HELP) return 0
if(I_DISARM) return 1
if(I_GRAB) return 2
if(INTENT_HELP) return 0
if(INTENT_DISARM) return 1
if(INTENT_GRAB) return 2
else return 3
else
switch(argument)
if(0) return I_HELP
if(1) return I_DISARM
if(2) return I_GRAB
else return I_HARM
if(0) return INTENT_HELP
if(1) return INTENT_DISARM
if(2) return INTENT_GRAB
else return INTENT_HARM
//change a mob's act-intent. Input the intent as a string such as "help" or use "right"/"left
/mob/verb/a_intent_change(input as text)
@@ -341,7 +341,7 @@ var/list/intents = list(I_HELP,I_DISARM,I_GRAB,I_HARM)
if(ishuman(src) || isalienadult(src) || isbrain(src))
switch(input)
if(I_HELP,I_DISARM,I_GRAB,I_HARM)
if(INTENT_HELP,INTENT_DISARM,INTENT_GRAB,INTENT_HARM)
a_intent = input
if("right")
a_intent = intent_numeric((intent_numeric(a_intent)+1) % 4)
@@ -352,14 +352,14 @@ var/list/intents = list(I_HELP,I_DISARM,I_GRAB,I_HARM)
else if(isrobot(src) || islarva(src))
switch(input)
if(I_HELP)
a_intent = I_HELP
if(I_HARM)
a_intent = I_HARM
if(INTENT_HELP)
a_intent = INTENT_HELP
if(INTENT_HARM)
a_intent = INTENT_HARM
if("right","left")
a_intent = intent_numeric(intent_numeric(a_intent) - 3)
if(hud_used && hud_used.action_intent)
if(a_intent == I_HARM)
if(a_intent == INTENT_HARM)
hud_used.action_intent.icon_state = "harm"
else
hud_used.action_intent.icon_state = "help"
+4 -4
View File
@@ -128,7 +128,7 @@
if("Drone")
new_xeno = new /mob/living/carbon/alien/humanoid/drone(loc)
new_xeno.a_intent = I_HARM
new_xeno.a_intent = INTENT_HARM
new_xeno.key = key
to_chat(new_xeno, "<B>You are now an alien.</B>")
@@ -187,7 +187,7 @@
qdel(t)
var/mob/living/simple_animal/pet/corgi/new_corgi = new /mob/living/simple_animal/pet/corgi (loc)
new_corgi.a_intent = I_HARM
new_corgi.a_intent = INTENT_HARM
new_corgi.key = key
to_chat(new_corgi, "<B>You are now a Corgi. Yap Yap!</B>")
@@ -218,7 +218,7 @@
var/mob/new_mob = new mobpath(src.loc)
new_mob.key = key
new_mob.a_intent = I_HARM
new_mob.a_intent = INTENT_HARM
to_chat(new_mob, "You suddenly feel more... animalistic.")
@@ -235,7 +235,7 @@
var/mob/new_mob = new mobpath(src.loc)
new_mob.key = key
new_mob.a_intent = I_HARM
new_mob.a_intent = INTENT_HARM
to_chat(new_mob, "You feel more... animalistic")
new_mob.update_pipe_vision()