Polaris sync

This commit is contained in:
killer653
2017-10-27 15:30:24 -04:00
226 changed files with 3156 additions and 1491 deletions
@@ -20,6 +20,7 @@
new /obj/item/weapon/gun/energy/gun(src)
new /obj/item/weapon/melee/telebaton(src)
new /obj/item/device/flash(src)
new /obj/item/weapon/storage/box/ids(src)
return
@@ -685,4 +685,5 @@
new /obj/item/clothing/under/gimmick/rank/captain/suit(src)
new /obj/item/clothing/under/gimmick/rank/captain/suit/skirt(src)
new /obj/item/clothing/glasses/sunglasses(src)
new /obj/item/clothing/head/caphat(src)
return
-72
View File
@@ -1,78 +1,6 @@
//trees
/obj/structure/flora/tree
name = "tree"
anchored = 1
density = 1
pixel_x = -16
layer = MOB_LAYER // You know what, let's play it safe.
/obj/structure/flora/tree/pine
name = "pine tree"
icon = 'icons/obj/flora/pinetrees.dmi'
icon_state = "pine_1"
/obj/structure/flora/tree/pine/New()
..()
icon_state = "pine_[rand(1, 3)]"
/obj/structure/flora/tree/pine/xmas
name = "xmas tree"
icon = 'icons/obj/flora/pinetrees.dmi'
icon_state = "pine_c"
/obj/structure/flora/tree/pine/xmas/New()
..()
icon_state = "pine_c"
/obj/structure/flora/tree/dead
icon = 'icons/obj/flora/deadtrees.dmi'
icon_state = "tree_1"
/obj/structure/flora/tree/dead/New()
..()
icon_state = "tree_[rand(1, 6)]"
/obj/structure/flora/tree/sif
name = "glowing tree"
desc = "It's a tree, except this one seems quite alien. It glows a deep blue."
icon = 'icons/obj/flora/deadtrees.dmi'
icon_state = "tree_sif"
/obj/structure/flora/tree/sif/New()
update_icon()
/obj/structure/flora/tree/sif/update_icon()
set_light(5, 1, "#33ccff")
overlays.Cut()
overlays.Add(image(icon = 'icons/obj/flora/deadtrees.dmi', icon_state = "[icon_state]_glow", layer = LIGHTING_LAYER + 0.1))
//grass
/obj/structure/flora/grass
name = "grass"
icon = 'icons/obj/flora/snowflora.dmi'
anchored = 1
/obj/structure/flora/grass/brown
icon_state = "snowgrass1bb"
/obj/structure/flora/grass/brown/New()
..()
icon_state = "snowgrass[rand(1, 3)]bb"
/obj/structure/flora/grass/green
icon_state = "snowgrass1gb"
/obj/structure/flora/grass/green/New()
..()
icon_state = "snowgrass[rand(1, 3)]gb"
/obj/structure/flora/grass/both
icon_state = "snowgrassall1"
/obj/structure/flora/grass/both/New()
..()
icon_state = "snowgrassall[rand(1, 3)]"
//bushes
@@ -0,0 +1,27 @@
//grass
/obj/structure/flora/grass
name = "grass"
icon = 'icons/obj/flora/snowflora.dmi'
anchored = 1
/obj/structure/flora/grass/brown
icon_state = "snowgrass1bb"
/obj/structure/flora/grass/brown/New()
..()
icon_state = "snowgrass[rand(1, 3)]bb"
/obj/structure/flora/grass/green
icon_state = "snowgrass1gb"
/obj/structure/flora/grass/green/New()
..()
icon_state = "snowgrass[rand(1, 3)]gb"
/obj/structure/flora/grass/both
icon_state = "snowgrassall1"
/obj/structure/flora/grass/both/New()
..()
icon_state = "snowgrassall[rand(1, 3)]"
+202
View File
@@ -0,0 +1,202 @@
//trees
/obj/structure/flora/tree
name = "tree"
anchored = 1
density = 1
pixel_x = -16
layer = MOB_LAYER // You know what, let's play it safe.
var/base_state = null // Used for stumps.
var/health = 200 // Used for chopping down trees.
var/max_health = 200
var/shake_animation_degrees = 4 // How much to shake the tree when struck. Larger trees should have smaller numbers or it looks weird.
var/obj/item/stack/material/product = null // What you get when chopping this tree down. Generally it will be a type of wood.
var/product_amount = 10 // How much of a stack you get, if the above is defined.
var/is_stump = FALSE // If true, suspends damage tracking and most other effects.
/obj/structure/flora/tree/attackby(var/obj/item/weapon/W, var/mob/living/user)
if(!istype(W))
return ..()
if(is_stump)
return
visible_message("<span class='danger'>\The [user] hits \the [src] with \the [W]!</span>")
var/damage_to_do = W.force
if(!W.sharp && !W.edge)
damage_to_do = round(damage_to_do / 4)
if(damage_to_do > 0)
if(W.sharp && W.edge)
playsound(get_turf(src), 'sound/effects/woodcutting.ogg', 50, 1)
else
playsound(get_turf(src), W.hitsound, 50, 1)
if(damage_to_do > 5)
adjust_health(-damage_to_do)
else
to_chat(user, "<span class='warning'>\The [W] is ineffective at harming \the [src].</span>")
hit_animation()
user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN)
user.do_attack_animation(src)
// Shakes the tree slightly, more or less stolen from lockers.
/obj/structure/flora/tree/proc/hit_animation()
var/init_px = pixel_x
var/shake_dir = pick(-1, 1)
animate(src, transform=turn(matrix(), shake_animation_degrees * shake_dir), pixel_x=init_px + 2*shake_dir, time=1)
animate(transform=null, pixel_x=init_px, time=6, easing=ELASTIC_EASING)
// Used when the tree gets hurt.
/obj/structure/flora/tree/proc/adjust_health(var/amount)
if(is_stump)
return
health = between(0, health + amount, max_health)
if(health <= 0)
die()
// Called when the tree loses all health, for whatever reason.
/obj/structure/flora/tree/proc/die()
if(is_stump)
return
if(product && product_amount) // Make wooden logs.
var/obj/item/stack/material/M = new product(get_turf(src))
M.amount = product_amount
M.update_icon()
visible_message("<span class='danger'>\The [src] is felled!</span>")
stump()
// Makes the tree into a mostly non-interactive stump.
/obj/structure/flora/tree/proc/stump()
if(is_stump)
return
is_stump = TRUE
icon_state = "[base_state]_stump"
overlays.Cut() // For the Sif tree and other future glowy trees.
set_light(0)
/obj/structure/flora/tree/ex_act(var/severity)
adjust_health(-(max_health / severity))
/obj/structure/flora/tree/get_description_interaction()
var/list/results = list()
if(!is_stump)
results += "[desc_panel_image("hatchet")]to cut down this tree into logs. Any sharp and strong weapon will do."
results += ..()
return results
// Subtypes.
// Pine trees
/obj/structure/flora/tree/pine
name = "pine tree"
icon = 'icons/obj/flora/pinetrees.dmi'
icon_state = "pine_1"
base_state = "pine"
product = /obj/item/stack/material/log
shake_animation_degrees = 3
/obj/structure/flora/tree/pine/New()
..()
icon_state = "[base_state]_[rand(1, 3)]"
/obj/structure/flora/tree/pine/xmas
name = "xmas tree"
icon = 'icons/obj/flora/pinetrees.dmi'
icon_state = "pine_c"
/obj/structure/flora/tree/pine/xmas/New()
..()
icon_state = "pine_c"
// Palm trees
/obj/structure/flora/tree/palm
icon = 'icons/obj/flora/palmtrees.dmi'
icon_state = "palm1"
base_state = "palm"
product = /obj/item/stack/material/log
product_amount = 5
health = 200
max_health = 200
pixel_x = 0
/obj/structure/flora/tree/palm/New()
..()
icon_state = "[base_state][rand(1, 2)]"
// Dead trees
/obj/structure/flora/tree/dead
icon = 'icons/obj/flora/deadtrees.dmi'
icon_state = "tree_1"
base_state = "tree"
product = /obj/item/stack/material/log
product_amount = 5
health = 200
max_health = 200
/obj/structure/flora/tree/dead/New()
..()
icon_state = "[base_state]_[rand(1, 6)]"
// Small jungle trees
/obj/structure/flora/tree/jungle_small
icon = 'icons/obj/flora/jungletreesmall.dmi'
icon_state = "tree"
base_state = "tree"
product = /obj/item/stack/material/log
product_amount = 10
health = 400
max_health = 400
pixel_x = -32
/obj/structure/flora/tree/jungle_small/New()
..()
icon_state = "[base_state][rand(1, 6)]"
// Big jungle trees
/obj/structure/flora/tree/jungle
icon = 'icons/obj/flora/jungletree.dmi'
icon_state = "tree"
base_state = "tree"
product = /obj/item/stack/material/log
product_amount = 20
health = 800
max_health = 800
pixel_x = -48
pixel_y = -16
shake_animation_degrees = 2
/obj/structure/flora/tree/jungle/New()
..()
icon_state = "[base_state][rand(1, 6)]"
// Sif trees
/obj/structure/flora/tree/sif
name = "glowing tree"
desc = "It's a tree, except this one seems quite alien. It glows a deep blue."
icon = 'icons/obj/flora/deadtrees.dmi'
icon_state = "tree_sif"
base_state = "tree_sif"
product = /obj/item/stack/material/log/sif
/obj/structure/flora/tree/sif/New()
update_icon()
/obj/structure/flora/tree/sif/update_icon()
set_light(5, 1, "#33ccff")
overlays.Cut()
overlays.Add(image(icon = 'icons/obj/flora/deadtrees.dmi', icon_state = "[icon_state]_glow", layer = LIGHTING_LAYER + 0.1))
-2
View File
@@ -68,7 +68,6 @@
new /obj/item/stack/rods(src.loc)
qdel(src)
return
// VOREStation Edit - Added Catwalks
if (istype(C, /obj/item/stack/rods))
var/obj/item/stack/rods/R = C
if(R.use(2))
@@ -78,7 +77,6 @@
new /obj/structure/catwalk(src.loc)
qdel(src)
return
// VOREStation Edit End
return
/obj/structure/lattice/proc/updateOverlays()
+2 -2
View File
@@ -1,7 +1,7 @@
// Based on railing.dmi from https://github.com/Endless-Horizon/CEV-Eris
/obj/structure/railing
name = "railing"
desc = "A standard steel railing. Play stupid games win stupid prizes."
desc = "A standard steel railing. Play stupid games, win stupid prizes."
icon = 'icons/obj/railing.dmi'
density = 1
throwpass = 1
@@ -103,7 +103,7 @@
/obj/structure/railing/update_icon(var/UpdateNeighgors = 1)
NeighborsCheck(UpdateNeighgors)
//layer = (dir == SOUTH) ? FLY_LAYER : initial(layer) // Vorestation edit because wtf does this even do
//layer = (dir == SOUTH) ? FLY_LAYER : initial(layer) // wtf does this even do
overlays.Cut()
if (!check || !anchored)//|| !anchored
icon_state = "railing0"
+10 -3
View File
@@ -13,6 +13,7 @@
var/maximal_heat = T0C + 100 // Maximal heat before this window begins taking damage from fire
var/damage_per_fire_tick = 2.0 // Amount of damage per fire tick. Regular windows are not fireproof so they might as well break quickly.
var/health
var/force_threshold = 0
var/ini_dir = null
var/state = 2
var/reinf = 0
@@ -313,9 +314,9 @@
return
/obj/structure/window/proc/hit(var/damage, var/sound_effect = 1)
if(reinf) damage *= 0.5
if(damage < 5)
if(damage < force_threshold || force_threshold < 0)
return
if(reinf) damage *= 0.5
take_damage(damage)
return
@@ -452,13 +453,14 @@
/obj/structure/window/basic
desc = "It looks thin and flimsy. A few knocks with... anything, really should shatter it."
desc = "It looks thin and flimsy. A few knocks with... almost anything, really should shatter it."
icon_state = "window"
basestate = "window"
glasstype = /obj/item/stack/material/glass
maximal_heat = T0C + 100
damage_per_fire_tick = 2.0
maxhealth = 12.0
force_threshold = 3
/obj/structure/window/phoronbasic
name = "phoron window"
@@ -470,6 +472,7 @@
maximal_heat = T0C + 2000
damage_per_fire_tick = 1.0
maxhealth = 40.0
force_threshold = 5
/obj/structure/window/phoronbasic/full
dir = SOUTHWEST
@@ -486,6 +489,7 @@
maximal_heat = T0C + 4000
damage_per_fire_tick = 1.0 // This should last for 80 fire ticks if the window is not damaged at all. The idea is that borosilicate windows have something like ablative layer that protects them for a while.
maxhealth = 80.0
force_threshold = 10
/obj/structure/window/phoronreinforced/full
dir = SOUTHWEST
@@ -501,6 +505,7 @@
maximal_heat = T0C + 750
damage_per_fire_tick = 2.0
glasstype = /obj/item/stack/material/glass/reinforced
force_threshold = 6
/obj/structure/window/New(Loc, constructed=0)
@@ -528,6 +533,7 @@
icon_state = "fwindow"
basestate = "fwindow"
maxhealth = 30
force_threshold = 5
/obj/structure/window/shuttle
name = "shuttle window"
@@ -539,6 +545,7 @@
reinf = 1
basestate = "w"
dir = 5
force_threshold = 7
/obj/structure/window/reinforced/polarized
name = "electrochromic window"