Fixed issues with canReach and atom/dblClick - clicking empty inv slot works now, and you don't have super-fast click ability.

This commit is contained in:
shadowlord13
2008-06-21 01:08:22 +00:00
parent 3a1eaf5207
commit d445c84383
4 changed files with 50 additions and 19 deletions
+24
View File
@@ -228,6 +228,7 @@
var/enable_drones = 0
var/humans_can_use_drones = 0
var/walkable_not_pullable_drones = 0
var/plasma_danger = 0
/datum/vote
var/voting = 0 // true if currently voting
@@ -465,6 +466,13 @@
var/a_level = 0.0
var/screen = 1.0
var/owner = null
/obj/barrier
name = "barrier"
icon = 'stationobjs.dmi'
icon_state = "barrier"
opacity = 1
density = 1
anchored = 1.0
/obj/beam
name = "beam"
/obj/beam/a_laser
@@ -656,6 +664,14 @@
name = "ion trails"
icon_state = "ion_trails"
anchored = 1.0
/obj/effects/water
name = "water"
icon = 'water.dmi'
icon_state = "extinguish"
var/life = 15.0
flags = 2.0
mouse_opacity = 0
weight = 1000
/obj/equip_e
name = "equip e"
var/mob/source = null
@@ -2455,6 +2471,14 @@ Total SMES charging rate should not exceed total power generation rate, or an ov
icon = 'screen1.dmi'
icon_state = "arrow"
layer = 16.0
/obj/portal
name = "portal"
icon = 'stationobjs.dmi'
icon_state = "portal"
density = 1
var/obj/target = null
anchored = 1.0
/obj/rack
name = "rack"
icon = 'Icons.dmi'
+3
View File
@@ -1165,6 +1165,7 @@
config.enable_drones = 0
config.humans_can_use_drones = 0
config.walkable_not_pullable_drones = 0
config.plasma_danger = 0
else
world.log << "Reading config.txt"
var/list/CL = dd_text2list(config_text, "\n")
@@ -1248,6 +1249,8 @@
config.humans_can_use_drones = 1
if("walkable_not_pullable_drones")
config.walkable_not_pullable_drones = 1
if("plasma_danger")
config.plasma_danger = 1
else
world.log<<"Unknown setting in config.txt: [cfgvar]"
+2 -2
View File
@@ -104,8 +104,8 @@ var
world_message = "Welcome to OpenSS13!"
savefile_ver = "4"
SS13_version = "1.0 \[Development Version]"
changes = {"<FONT color='blue'><B>Changes from base version 40.93.2</B></FONT><BR>
SS13_version = "1.0 \[Development Version] - 6/20/2008"
changes = {"<FONT color='blue'><H1>Version: [SS13_version]</H1><B>Changes from base version 40.93.2</B></FONT><BR>
<HR>
<!--
<p><B>This is a test version which hasn't been released yet, the reason being to test new bugfixes and/or features to see if they're all working without having broken anything else.
+21 -17
View File
@@ -5685,7 +5685,7 @@
/* flag 16 in this case apparently disables the distance check and the alternate 'is in contents' check in the var/t5 line.
It's used on guns, for instance. --shadowlord13 */
if (((t5 || (usingWeapon && (usingWeapon.flags & 16))) && !(istype(src, /obj/screen))))
if (ignoreNextMoveTime!=0)
if (ignoreNextMoveTime==0)
if (user.next_move < world.time)
user.prev_move = user.next_move
user.next_move = world.time + 10
@@ -5773,7 +5773,7 @@
return (((t5!=0)&1)<<1) | ((usingWeapon!=0)&1) | CANREACH_ALLOWED
else
if (istype(src, /obj/screen))
if (ignoreNextMoveTime!=0)
if (ignoreNextMoveTime==0)
if (user.next_move < world.time)
user.prev_move = user.next_move
user.next_move = world.time + 10
@@ -5791,7 +5791,7 @@
return
else
usr:lastDblClick = world.time
..()
// I changed everything in this function from using usr to user before I found out that you can actually change the value of usr.
var/mob/user = usr
@@ -5840,20 +5840,24 @@
//if (((t5 || (usingWeapon && (usingWeapon.flags & 16))) && !(istype(src, /obj/screen))))
if (retval & CANREACH_ALLOWED)
if (!(istype(src, /obj/screen)))
if (!user.restrained())
if (W)
if (retval & CANREACH_CANTOUCH)
src.attackby(W, user)
if (W)
W.afterattack(src, user, ((retval & CANREACH_CANTOUCH) ? 1 : 0))
else
if (istype(user, /mob/human) || istype(user, /mob/drone))
src.attack_hand(user, user.hand)
else
if (istype(user, /mob/monkey))
src.attack_paw(user, user.hand)
if (!( user.restrained() ))
if ((W && !( istype(src, /obj/screen) )))
src.attackby(W, user)
if (W)
W.afterattack(src, user)
else
if (istype(user, /mob/human))
src.attack_hand(user, user.hand)
else
if (istype(user, /mob/monkey))
src.attack_paw(user, user.hand)
else
if (istype(user, /mob/human))
src.hand_h(user, user.hand)
else
if (istype(user, /mob/monkey))
src.hand_p(user, user.hand)
/obj/proc/updateDialog()
var/list/nearby = viewers(1, src)