Merge remote-tracking branch 'upstream/master'

This commit is contained in:
Tastyfish
2012-01-08 20:06:03 -05:00
22 changed files with 6641 additions and 6589 deletions

View File

@@ -5,7 +5,6 @@
//yes, it has to be an item, you can't pick up nonitems
var/list/CustomItemList = list(
// ckey real_name item path
// list("miniature","Dave Booze",/obj/item/toy/crayonbox) //screw this i dont want crayons, it's an example okay
list("skymarshal", "Phillip Oswald", /obj/item/weapon/coin/silver), //Phillip likes to chew on cigars. Just unlit cigars, don't ask me why. Must be a clone thing. (Cigarette machines dispense cigars if they have a coin in them) --SkyMarshal
list("spaceman96", "Trenna Seber", /obj/item/weapon/pen/multi), //For Spesss.
list("asanadas", "Book Berner", /obj/item/clothing/under/chameleon/psyche)

View File

@@ -105,8 +105,11 @@
/obj/item/policetape/attack_hand(mob/user as mob)
breaktape(null, user)
/obj/item/policetape/attack_paw(mob/user as mob)
breaktape(/obj/item/weapon/wirecutters,user)
/obj/item/policetape/proc/breaktape(obj/item/weapon/W as obj, mob/user as mob)
if(!W && user.a_intent != "help" || (!is_sharp(W) && src.allowed(user)) ||(!is_cut(W) && !src.allowed(user)))
if(user.a_intent == "help" && ((!is_sharp(W) && src.allowed(user)) ||(!is_cut(W) && !src.allowed(user))))
user << "You can't break the tape with that!"
return
user.show_viewers(text("\blue [] breaks the police tape!", user))

View File

@@ -681,7 +681,7 @@
update_icon()
spawn(2) //So it properly updates when deleting
var/dir_sum = 0
for(var/direction in cardinal)
for(var/direction in list(1,2,4,8,5,6,9,10))
var/skip_sum = 0
for(var/obj/structure/window/W in src.loc)
if(W.dir == direction) //So smooth tables don't go smooth through windows
@@ -697,15 +697,35 @@
inv_direction = 8
if(8)
inv_direction = 4
if(5)
inv_direction = 10
if(6)
inv_direction = 9
if(9)
inv_direction = 6
if(10)
inv_direction = 5
for(var/obj/structure/window/W in get_step(src,direction))
if(W.dir == inv_direction) //So smooth tables don't go smooth through windows when the window is on the other table's tile
skip_sum = 1
continue
if(!skip_sum) //means there is a window between the two tiles in this direction
if(locate(/obj/structure/table,get_step(src,direction)))
dir_sum += direction
if(direction <5)
dir_sum += direction
else
if(direction == 5) //This permits the use of all table directions. (Set up so clockwise around the central table is a higher value, from north)
dir_sum += 16
if(direction == 6)
dir_sum += 32
if(direction == 8) //Aherp and Aderp. Jezes I am stupid. -- SkyMarshal
dir_sum += 8
if(direction == 10)
dir_sum += 64
if(direction == 9)
dir_sum += 128
//dir_sum:
//dir_sum%16:
// 1,2,4,8 = endtable
// 3,12 = streight 1 tile thick table
// 5,6,9,10 = corner, if it finds a table in get_step(src,dir_sum) then it's a full corner table, else it's a 1 tile chick corner table
@@ -720,31 +740,73 @@
// 4 = middle table (full, 4 connections)
var/table_type = 0 //stand_alone table
if(dir_sum in cardinal)
if(dir_sum%16 in cardinal)
table_type = 1 //endtable
if(dir_sum in list(3,12))
dir_sum %= 16
if(dir_sum%16 in list(3,12))
table_type = 2 //1 tile thick, streight table
if(dir_sum == 3) //3 doesn't exist as a dir
if(dir_sum%16 == 3) //3 doesn't exist as a dir
dir_sum = 2
if(dir_sum == 12) //12 doesn't exist as a dir.
if(dir_sum%16 == 12) //12 doesn't exist as a dir.
dir_sum = 4
if(dir_sum in list(5,6,9,10))
if(locate(/obj/structure/table,get_step(src.loc,dir_sum)))
if(dir_sum%16 in list(5,6,9,10))
if(locate(/obj/structure/table,get_step(src.loc,dir_sum%16)))
table_type = 3 //full table (not the 1 tile thick one, but one of the 'tabledir' tables)
else
table_type = 2 //1 tile thick, corner table (treated the same as streight tables in code later on)
if(dir_sum in list(13,14,7,11)) //Three-way intersection
table_type = 3 //full table as three-way intersections are not sprited, would require 64 sprites to handle all combinations
switch(dir_sum)
dir_sum %= 16
if(dir_sum%16 in list(13,14,7,11)) //Three-way intersection
table_type = 5 //full table as three-way intersections are not sprited, would require 64 sprites to handle all combinations. TOO BAD -- SkyMarshal
switch(dir_sum%16) //Begin computation of the special type tables. --SkyMarshal
if(7)
dir_sum = 4
if(dir_sum == 23)
table_type = 6
dir_sum = 8
else if(dir_sum == 39)
dir_sum = 4
table_type = 6
else if(dir_sum == 55 || dir_sum == 119 || dir_sum == 247 || dir_sum == 183)
dir_sum = 4
table_type = 3
else
dir_sum = 4
if(11)
dir_sum = 8
if(dir_sum == 75)
dir_sum = 5
table_type = 6
else if(dir_sum == 139)
dir_sum = 9
table_type = 6
else if(dir_sum == 203 || dir_sum == 219 || dir_sum == 251 || dir_sum == 235)
dir_sum = 8
table_type = 3
else
dir_sum = 8
if(13)
dir_sum = 1
if(dir_sum == 29)
dir_sum = 6
table_type = 6
else if(dir_sum == 141)
dir_sum = 10
table_type = 6
else if(dir_sum == 189 || dir_sum == 221 || dir_sum == 253 || dir_sum == 157)
dir_sum = 1
table_type = 3
else
dir_sum = 1
if(14)
dir_sum = 2 //These translate the dir_sum to the correct dirs from the 'tabledir' icon_state.
if(dir_sum == 15)
if(dir_sum == 46)
dir_sum = 1
table_type = 6
else if(dir_sum == 78)
dir_sum = 2
table_type = 6
else if(dir_sum == 110 || dir_sum == 254 || dir_sum == 238 || dir_sum == 126)
dir_sum = 2
table_type = 3
else
dir_sum = 2 //These translate the dir_sum to the correct dirs from the 'tabledir' icon_state.
if(dir_sum%16 == 15)
table_type = 4 //4-way intersection, the 'middle' table sprites will be used.
if(istype(src,/obj/structure/table/reinforced))
@@ -759,6 +821,10 @@
icon_state = "reinf_tabledir"
if(4)
icon_state = "reinf_middle"
if(5)
icon_state = "reinf_tabledir2"
if(6)
icon_state = "reinf_tabledir3"
else if(istype(src,/obj/structure/table/woodentable))
switch(table_type)
if(0)
@@ -771,6 +837,10 @@
icon_state = "wood_tabledir"
if(4)
icon_state = "wood_middle"
if(5)
icon_state = "wood_tabledir2"
if(6)
icon_state = "wood_tabledir3"
else
switch(table_type)
if(0)
@@ -783,6 +853,10 @@
icon_state = "tabledir"
if(4)
icon_state = "table_middle"
if(5)
icon_state = "tabledir2"
if(6)
icon_state = "tabledir3"
if (dir_sum in list(1,2,4,8,5,6,9,10))
dir = dir_sum
else

View File

@@ -32,8 +32,8 @@
/obj/item/clothing/under/chameleon/psyche
item_state = "bl_suit"
name = "psychedelic"
desc = "Groovy!"
name = "Groovy Jumpsuit"
desc = "A groovy jumpsuit! It seems to have a small dial on the wrist, that won't stop spinning."
icon_state = "psyche"
color = "psyche"

View File

@@ -4,7 +4,7 @@
command_alert("The station is now in a meteor shower", "Meteor Alert")
Tick()
if (prob(40))
if (prob(20))
meteor_wave()
Die()

View File

@@ -3,80 +3,75 @@
/var/const/meteor_wave_delay = 625 //minimum wait between waves in tenths of seconds
//set to at least 100 unless you want evarr ruining every round
/var/const/meteors_in_wave = 50
/var/const/meteors_in_wave = 20
/var/const/meteors_in_small_wave = 10
/proc/meteor_wave(var/number = meteors_in_wave)
if(!ticker || wavesecret)
return
wavesecret = 1
for(var/i = 0 to number)
spawn(rand(10,100))
spawn_meteor()
spawn(meteor_wave_delay)
wavesecret = 0
/proc/spawn_meteors(var/number = meteors_in_small_wave)
for(var/i = 0; i < number; i++)
spawn(0)
spawn_meteor()
/proc/spawn_meteor()
var/startx
var/starty
var/endx
var/endy
var/turf/pickedstart
var/turf/pickedgoal
var/max_i = 10//number of tries to spawn meteor.
switch(pick(1,2,3,4))
if(1) //NORTH
starty = world.maxy-3
startx = rand(1, world.maxx-1)
endy = 1
endx = rand(1, world.maxx-1)
if(2) //EAST
starty = rand(1,world.maxy-1)
startx = world.maxx-3
endy = rand(1, world.maxy-1)
endx = 1
if(3) //SOUTH
starty = 3
startx = rand(1, world.maxx-1)
endy = world.maxy-1
endx = rand(1, world.maxx-1)
if(4) //WEST
starty = rand(1, world.maxy-1)
startx = 3
endy = rand(1,world.maxy-1)
endx = world.maxx-1
pickedstart = locate(startx, starty, 1)
pickedgoal = locate(endx, endy, 1)
wavesecret = 1
for(var/i = 0 to number)
spawn(rand(10,100))
spawn_meteor(pickedstart, pickedgoal)
spawn(meteor_wave_delay)
wavesecret = 0
/proc/spawn_meteors(var/turf/pickedstart, var/turf/pickedgoal, var/number = meteors_in_small_wave)
for(var/i = 0; i < number; i++)
spawn(0)
spawn_meteor(pickedstart, pickedgoal)
do
switch(pick(1,2,3,4))
if(1) //NORTH
starty = world.maxy-3
startx = rand(1, world.maxx-1)
endy = 1
endx = rand(1, world.maxx-1)
if(2) //EAST
starty = rand(1,world.maxy-1)
startx = world.maxx-3
endy = rand(1, world.maxy-1)
endx = 1
if(3) //SOUTH
starty = 3
startx = rand(1, world.maxx-1)
endy = world.maxy-1
endx = rand(1, world.maxx-1)
if(4) //WEST
starty = rand(1, world.maxy-1)
startx = 3
endy = rand(1,world.maxy-1)
endx = world.maxx-1
/proc/spawn_meteor(var/turf/pickedstart, var/turf/pickedgoal)
pickedstart = locate(startx, starty, 1)
pickedgoal = locate(endx, endy, 1)
max_i--
if(max_i<=0) return
var/route = rand(1,5)
var/turf/tempgoal = pickedgoal
for(var/i, i < route, i++)
tempgoal = get_step(tempgoal,rand(1,8))
while (!istype(pickedstart, /turf/space) || pickedstart.loc.name != "Space" ) //FUUUCK, should never happen.
var/obj/effect/meteor/M
switch(rand(1, 100))
if(1 to 15)
M = new /obj/effect/meteor/big(pickedstart)
if(16 to 75)
M = new /obj/effect/meteor( pickedstart )
if(76 to 100)
M = new /obj/effect/meteor/small( pickedstart )
var/obj/effect/meteor/M
switch(rand(1, 100))
if(1 to 20)
M = new /obj/effect/meteor/big( pickedstart )
if(21 to 75)
M = new /obj/effect/meteor( pickedstart )
if(76 to 100)
M = new /obj/effect/meteor/small( pickedstart )
M.dest = pickedgoal
spawn(0)
walk_towards(M, M.dest, 1)
M.dest = tempgoal
spawn(0)
walk_towards(M, M.dest, 1)
return

View File

@@ -168,18 +168,17 @@ THERMAL GLASSES
if(!A)
return
desc = null
permeability_coefficient = 0.90
desc = A.desc
name = A.name
desc = A.desc
icon_state = A.icon_state
item_state = A.item_state
color = A.color
/obj/item/clothing/under/chameleon/emp_act(severity)
name = "psychedelic"
desc = "Groovy!"
name = "Groovy Jumpsuit"
desc = "A groovy jumpsuit! It seems to have a small dial on the wrist, that won't stop spinning."
icon_state = "psyche"
color = "psyche"
spawn(200)
@@ -189,6 +188,9 @@ THERMAL GLASSES
desc = null
..()
/obj/item/clothing/under/chameleon/psyche/emp_act(severity)
return
/*
/obj/item/clothing/suit/swat_suit/death_commando
name = "Death Commando Suit"

View File

@@ -191,7 +191,7 @@
damtype = "brute"
if (href_list["amount"])
src.throw_amount = src.throw_amount + text2num(href_list["amount"])
src.throw_amount = max(50,min(5000,src.throw_amount))
src.throw_amount = max(90,min(300,src.throw_amount))
if (href_list["remove"])
if(!src.ptank) return
var/obj/item/weapon/tank/plasma/A = src.ptank
@@ -235,7 +235,7 @@
/obj/item/weapon/flamethrower/proc/ignite_turf(turf/target)
//TODO: DEFERRED Consider checking to make sure tank pressure is high enough before doing this...
//Transfer 5% of current tank air contents to turf
var/datum/gas_mixture/air_transfer = ptank.air_contents.remove_ratio(0.05)
var/datum/gas_mixture/air_transfer = ptank.air_contents.remove_ratio(0.05*throw_amount/100)
air_transfer.toxins = air_transfer.toxins * 5 // This is me not comprehending the air system. I realize this is retarded and I could probably make it work without fucking it up like this, but there you have it. -- TLE
target.assume_air(air_transfer)
//Burn it based on transfered gas

View File

@@ -91,7 +91,7 @@ CLIPBOARDS
return
for(var/mob/O in viewers(user))
O.show_message("\blue [user] starts writing on the paper with [src].", 1)
O.show_message("\blue [user] starts writing on the paper with [P].", 1)
var/t = "[src.info]"
do
t = input(user, "What text do you wish to add?", text("[]", src.name), t) as message

View File

@@ -357,4 +357,5 @@
F.ptank = src
user.before_take_item(src)
src.loc = F
F.update_icon()
return

View File

@@ -159,9 +159,6 @@ var/specops_shuttle_timeleft = 0
if(specops_shuttle_moving_to_station || specops_shuttle_moving_to_centcom) return 0
else return 1
/obj/machinery/computer/specops_shuttle/attackby(I as obj, user as mob)
return attack_hand(user)
/obj/machinery/computer/specops_shuttle/attack_ai(var/mob/user as mob)
return attack_hand(user)

View File

@@ -1890,19 +1890,23 @@
if(istype(H.wear_id, /obj/item/device/pda))
var/obj/item/device/pda/PDA = H.wear_id
id = PDA.id // The ID is contained inside the PDA
else
id = H.wear_id
if(!isnull(PDA.id)) // The PDA may contain no ID
id = PDA.id // The ID is contained inside the PDA
if(!id)
usr << "<font color=red>ERROR:</font> Inform the coders that an [H.name] had wear_id but no ID on their ID slot."
dat += "<td><font color=red>ERROR</font></td>"
else if(isnull(id.assignment))
usr << "<font color=red>ERROR:</font> Inform the coders that an [id.name] was checked for its assignment variable."
else
id = H.wear_id // The ID was on the ID slot
if(!id) // Happens when there's no ID in the PDA located on the wear_id slot
dat += "<td>[M.mind.assigned_role] (No ID)</td>"
else if(isnull(id.assignment)) // Preventing runtime errors blocking the player panel
usr << "<font color=red>ERROR:</font> Inform the coders that an [id.name] was checked for its assignment variable, and it was null."
dat += "<td><font color=red>ERROR</font></td>"
else
if(M.mind.assigned_role == id.assignment) // Polymorph
dat += "<td>[M.mind.assigned_role]</td>"
else
dat += "<td>[M.mind.assigned_role] ([id.assignment])"

View File

@@ -779,7 +779,9 @@
if(!istype(M, /mob/living/carbon/human))
usr << "\red You can only do this to humans!"
return
switch(alert("You sure you wish to edit this mob's appearance?",,"Yes","No"))
if("No")
return
var/new_facial = input("Please select facial hair color.", "Character Generation") as color
if(new_facial)
M.r_facial = hex2num(copytext(new_facial, 2, 4))

View File

@@ -156,8 +156,8 @@
if(stat & NOPOWER) return
if(!charging_reagents) return
use_power(5000)
src.energy += 0.01
use_power(10000)
src.energy += 0.05
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

View File

@@ -172,8 +172,7 @@
afterattack(atom/target as mob|obj|turf|area, mob/user as mob)
if (istype(target, /obj/item/weapon/storage)) return ..()
if (istype(target, /obj/item/weapon/gun/grenadelauncher)) return ..()
if (istype(target, /obj/item/weapon/storage || istype(target, /obj/item/weapon/gun/grenadelauncher) || istype(target, /obj/structure/table))) return ..()
if (!src.state && stage == 2 && !crit_fail)
user << "\red You prime the grenade! 3 seconds!"
message_admins("[key_name_admin(user)] used a chemistry grenade ([src.name]).")

View File

@@ -521,7 +521,7 @@
else if (istype(AM, /mob)) //If there is a mob somewhere in there....
tagOverride = 1
if(tagOverride)
if(prob(50))
if(prob(25))
src.destinationTag = null //Then 50% chance of going to the mail room!

View File

@@ -54,6 +54,8 @@
examine()
set src in oview(4)
if(sortTag)
usr << "\blue It is labeled \"[sortTag]\""
if(examtext)
usr << examtext
..()
@@ -111,6 +113,8 @@
examine()
set src in oview(4)
if(sortTag)
usr << "\blue It is labeled \"[sortTag]\""
if(examtext)
usr << examtext
..()

View File

@@ -90,6 +90,9 @@ Note: Must be placed within 3 tiles of the R&D Console
busy = 1
loaded_item = O
user.drop_item()
if(istype(O,/obj/item/weapon/storage))
var/obj/item/weapon/storage/L = O
L.close(user)
O.loc = src
user << "\blue You add the [O.name] to the machine!"
flick("d_analyzer_la", src)

View File

@@ -61,7 +61,7 @@
// trigger a response team
spawn
sleep(6000)
sleep(100)
if(security_level == SEC_LEVEL_RED) trigger_armed_response_team()
if(SEC_LEVEL_DELTA)
world << "<font size=4 color='red'>Attention! Delta security level reached!</font>"

Binary file not shown.

Before

Width:  |  Height:  |  Size: 45 KiB

After

Width:  |  Height:  |  Size: 54 KiB

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff