Various Tweaks

Moved to mousedrop system. Meaning it will need to wait for other things
to go to that system but i am not in a rush,
Put the head sprites back into head DMI.
However i am having an issue with the sprite appearing on the holders
head now.
For somereason i have to tell it to put it in the active hand or it no
work.

Took the Viro bits out of the bioscan attempted to adjust the window
sizeing.

I probaly missed something.
This commit is contained in:
Aurorablade
2015-07-03 00:12:40 -04:00
parent 9dcfbe797d
commit 5b22a1750a
7 changed files with 26 additions and 67 deletions
+2 -2
View File
@@ -44,12 +44,12 @@
src.forceMove(H)
H.name = name
if(desc) H.desc = desc
H.attack_hand(grabber)
H.MouseDrop(grabber)
grabber << "<span class='notice'>You scoop up \the [src]."
src << "<span class='notice'>\The [grabber] scoops you up.</span>"
grabber.status_flags |= PASSEMOTES
return
return H
//Mob specific holders.
+20 -26
View File
@@ -152,14 +152,6 @@
/mob/living/silicon/pai/MouseDrop(atom/over_object)
return
//Below was the orignal mousedrop code from Bay, keeping incase.
// var/mob/living/carbon/H = over_object
// if(!istype(H) || !Adjacent(H)) return ..()
// if(H.a_intent == "help")
// get_scooped(H)
// return
// else
// return ..()
/mob/living/silicon/pai/emp_act(severity)
// Silence for 2 minutes
@@ -441,13 +433,9 @@
/mob/living/silicon/pai/attack_hand(mob/user as mob)
if(stat == 2) return
if(user.a_intent == "help")
get_scooped(user)
return
else
visible_message("<span class='danger'>[user.name] boops [src] on the head.</span>")
spawn(1)
close_up()
visible_message("<span class='danger'>[user.name] boops [src] on the head.</span>")
spawn(1)
close_up()
//I'm not sure how much of this is necessary, but I would rather avoid issues.
/mob/living/silicon/pai/proc/close_up()
@@ -537,16 +525,22 @@
// Handle being picked up.
/mob/living/silicon/pai/get_scooped(var/mob/living/carbon/grabber)
if(!holder_type) return
var/obj/item/weapon/holder/pai/H = new(loc)
//H.attack_hand(grabber)
src.forceMove(H)
H.icon_override = 'icons/mob/in-hand/paiheld.dmi'
var/obj/item/weapon/holder/H = ..()
if(!istype(H))
return
H.icon_override = 'icons/mob/in-hand/paiheld.dmi'//I have these in diffrent DMI so i am overriding
H.icon_state = "pai-[icon_state]"
grabber.put_in_active_hand(H)
grabber.update_icons()
H.icon_override = 'icons/mob/paihat.dmi'
H.item_state = "pai-[icon_state]"
grabber.put_in_active_hand(H)//for some reason unless i call this it dosen't work
grabber.update_inv_l_hand()
grabber.update_inv_r_hand()
return H
return H
/mob/living/silicon/pai/MouseDrop(atom/over_object)
var/mob/living/carbon/H = over_object
if(!istype(H) || !Adjacent(H)) return ..()
if(H.a_intent == "help")
get_scooped(H)
return
else
return ..()
@@ -562,43 +562,27 @@
var/count = 0
// Find the carrier
while(!istype(held, /mob/living))
while(!isliving(held))
if(!held || !held.loc || count > 6)
//For a runtime where M ends up in nullspace (similar to bluespace but less colourful)
src << "You are not being carried by anyone!"
return 0
held = held.loc
count++
if(istype(held, /mob/living))
if(isliving(held))
data["holder"] = held
data["health"] = "[held.stat > 1 ? "dead" : "[held.health]% healthy"]"
data["oxy"] = "[held.getOxyLoss() > 50 ? "<font color=#FF5555>" : "<font color=#55FF55>"][held.getOxyLoss()]</font>"
data["tox"] = "[held.getToxLoss() > 50 ? "<font color=#FF5555>" : "<font color=#55FF55>"][held.getToxLoss()]</font>"
data["burn"] = "[held.getFireLoss() > 50 ? "<font color=#FF5555>" : "<font color=#55FF55>"][held.getFireLoss()]</font>"
data["temp"] = "[held.bodytemperature-T0C]&deg;C ([held.bodytemperature*1.8-459.67]&deg;F)"
//data["infected"] = null
if (held.viruses)
data["infected"] = 1
var/virus[0]
for((var/datum/disease2/disease/D in held.viruses))
var/vdata[0]
vdata["name"] = D.name() || "unknown"
vdata["type"] = D.spreadtype || "unknown"
vdata["stage"] = D.stage || "unknown"
vdata["stageMax"] = D.max_stage || "unknown"
vdata["cure"] = D.antigen || "unknown"
virus[++virus.len]=vdata
data["infectionDat"] = virus
else
data["holder"] = 0
ui = nanomanager.try_update_ui(user, user, id, ui,data , force_open)
if(!ui)
// Don't copy-paste this unless you're making a pAI software module!
ui = new(user, user, id, "pai_bioscan.tmpl", "Host Bioscan", 400, 450)
ui = new(user, user, id, "pai_bioscan.tmpl", "Host Bioscan", 400, 350)
ui.set_initial_data(data)
ui.open()
//.set_auto_update(1)
Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 209 KiB

After

Width:  |  Height:  |  Size: 211 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

+1 -20
View File
@@ -5,7 +5,7 @@ code/modules/mob/living/silicon/pai/software_modules.dm
{{if data.holder}}
<div class="item">
<div class="itemLabel">
Bioscan Results for {{:data.holder}}:
Bioscan Results for {{:data.holder}} :
</div>
<div class="itemContent">
Health Status : {{:data.health}}
@@ -22,25 +22,6 @@ code/modules/mob/living/silicon/pai/software_modules.dm
User Temprature : {{:data.temp}}
</div>
</div>
{{if data.infected}}
<span class="bad"> Alert:Viral pathogen detected, Attempting to find information... </span>
{{for data.infectionDat}}
<div class="item">
<div class="itemLabel">
{{:value.name}}:
</div>
<div class="itemContent">
Type : {{:value.type}}
</div>
<div class="itemContent">
Stage: {{:value.stage}} / {{:value.stagemax}}
<div class="itemContent">
Possible Cure or Antigen: {{:value.cure}}
</div>
</div>
{{/for}}
{{/if}}
{{else}}
<span class="bad">Error: No biological host found!</span>
{{/if}}