Merge remote-tracking branch 'upstream/master'
This commit is contained in:
@@ -131,7 +131,6 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb
|
||||
//Tooltip vars
|
||||
var/force_string //string form of an item's force. Edit this var only to set a custom force string
|
||||
var/last_force_string_check = 0
|
||||
var/tip_timer
|
||||
|
||||
var/trigger_guard = TRIGGER_GUARD_NONE
|
||||
|
||||
@@ -451,7 +450,8 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb
|
||||
A.Remove(user)
|
||||
if(item_flags & DROPDEL)
|
||||
qdel(src)
|
||||
item_flags &= ~IN_INVENTORY
|
||||
DISABLE_BITFIELD(item_flags, IN_INVENTORY)
|
||||
DISABLE_BITFIELD(item_flags, IN_STORAGE)
|
||||
SEND_SIGNAL(src, COMSIG_ITEM_DROPPED,user)
|
||||
remove_outline()
|
||||
// if(!silent)
|
||||
@@ -529,6 +529,8 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb
|
||||
if(item_action_slot_check(slot, user, A)) //some items only give their actions buttons when in a specific slot.
|
||||
A.Grant(user)
|
||||
item_flags |= IN_INVENTORY
|
||||
if(CHECK_BITFIELD(item_flags, IN_STORAGE)) // Left storage item but somehow has the bitfield active still.
|
||||
DISABLE_BITFIELD(item_flags, IN_STORAGE)
|
||||
// if(!initial)
|
||||
// if(equip_sound && (slot_flags & slot))
|
||||
// playsound(src, equip_sound, EQUIP_SOUND_VOLUME, TRUE, ignore_walls = FALSE)
|
||||
@@ -885,10 +887,9 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb
|
||||
|
||||
/obj/item/MouseEntered(location, control, params)
|
||||
SEND_SIGNAL(src, COMSIG_ITEM_MOUSE_ENTER, location, control, params)
|
||||
if((item_flags & IN_INVENTORY || item_flags & IN_STORAGE) && usr.client.prefs.enable_tips && !QDELETED(src))
|
||||
var/timedelay = usr.client.prefs.tip_delay/100
|
||||
var/user = usr
|
||||
tip_timer = addtimer(CALLBACK(src, .proc/openTip, location, control, params, user), timedelay, TIMER_STOPPABLE)//timer takes delay in deciseconds, but the pref is in milliseconds. dividing by 100 converts it.
|
||||
if((item_flags & IN_INVENTORY || item_flags & IN_STORAGE) && usr?.client.prefs.enable_tips && !QDELETED(src))
|
||||
var/timedelay = max(usr.client.prefs.tip_delay * 0.01, 0.01) // I heard multiplying is faster, also runtimes from very low/negative numbers
|
||||
usr.client.tip_timer = addtimer(CALLBACK(src, .proc/openTip, location, control, params, usr), timedelay, TIMER_STOPPABLE)//timer takes delay in deciseconds, but the pref is in milliseconds. dividing by 100 converts it.
|
||||
var/mob/living/L = usr
|
||||
if(istype(L) && (L.incapacitated() || (current_equipped_slot in L.check_obscured_slots()) || !L.canUnEquip(src)))
|
||||
apply_outline(_size = 3)
|
||||
@@ -901,7 +902,6 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb
|
||||
|
||||
/obj/item/MouseExited(location,control,params)
|
||||
SEND_SIGNAL(src, COMSIG_ITEM_MOUSE_EXIT, location, control, params)
|
||||
deltimer(tip_timer)//delete any in-progress timer if the mouse is moved off the item before it finishes
|
||||
closeToolTip(usr)
|
||||
remove_outline()
|
||||
|
||||
|
||||
@@ -15,6 +15,6 @@
|
||||
var/indelay = stripped_input(usr, "Enter the tooltip delay in milliseconds (default: 500)", "Enter tooltip delay", "", 10)
|
||||
indelay = text2num(indelay)
|
||||
if(usr)//is this what you mean?
|
||||
prefs.tip_delay = indelay
|
||||
prefs.tip_delay = max(indelay, 0.01)
|
||||
prefs.save_preferences()
|
||||
to_chat(usr, "<span class='danger'>Tooltip delay set to [indelay] milliseconds.</span>")
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
var/pirate_type = PIRATES_ROGUES //pick(PIRATES_ROGUES, PIRATES_SILVERSCALES, PIRATES_DUTCHMAN)
|
||||
var/datum/comm_message/threat_msg = new
|
||||
var/payoff = 0
|
||||
var/payoff_min = 10000
|
||||
var/payoff_min = 1000
|
||||
var/ship_template
|
||||
var/ship_name = "Space Privateers Association"
|
||||
var/initial_send_time = world.time
|
||||
|
||||
@@ -246,15 +246,15 @@
|
||||
mag_type = /obj/item/ammo_box/magazine/internal/shot/com
|
||||
w_class = WEIGHT_CLASS_NORMAL
|
||||
var/stock = FALSE
|
||||
var/extend_sound = 'sound/weapons/batonextend.ogg'
|
||||
recoil = 5
|
||||
spread = 2
|
||||
|
||||
/obj/item/gun/ballistic/shotgun/automatic/combat/compact/AltClick(mob/living/user)
|
||||
. = ..()
|
||||
if(!istype(user) || !user.canUseTopic(src, BE_CLOSE, ismonkey(user)) || item_flags && IN_STORAGE)
|
||||
if(!istype(user) || !user.canUseTopic(src, BE_CLOSE, ismonkey(user)) || item_flags & IN_STORAGE)
|
||||
return
|
||||
toggle_stock(user)
|
||||
return TRUE
|
||||
. = ..()
|
||||
|
||||
/obj/item/gun/ballistic/shotgun/automatic/combat/compact/examine(mob/user)
|
||||
. = ..()
|
||||
@@ -272,6 +272,7 @@
|
||||
to_chat(user, "You fold the stock.")
|
||||
recoil = 5
|
||||
spread = 2
|
||||
playsound(src.loc, extend_sound, 50, 1)
|
||||
update_icon()
|
||||
|
||||
/obj/item/gun/ballistic/shotgun/automatic/combat/compact/update_icon_state()
|
||||
|
||||
@@ -119,15 +119,18 @@ Notes:
|
||||
//Includes sanity checks.
|
||||
/proc/closeToolTip(mob/user)
|
||||
if(istype(user))
|
||||
if(user.client && user.client.tooltips)
|
||||
user.client.tooltips.hide()
|
||||
if(user.client)
|
||||
var/client/client = user.client
|
||||
if(client.tooltips)
|
||||
client.tooltips.hide()
|
||||
deltimer(client.tip_timer) //delete any in-progress timer if the mouse is moved off the item before it finishes
|
||||
client.tip_timer = null
|
||||
|
||||
/**
|
||||
* # `get_tooltip_data()`
|
||||
*
|
||||
* If set, will return a list for the tooltip (that will also be put together in a `Join()`)
|
||||
* However, if returning `null`, falls back to default behavior, which is `examine(src)`, and it will definitely include
|
||||
* images since it is the default behavior
|
||||
* However, if returning `null`, the tooltip will not be shown as #14942 changed it.
|
||||
*
|
||||
* Though no tooltips will be created for atoms that have `tooltips = FALSE`
|
||||
*/
|
||||
@@ -137,11 +140,12 @@ Notes:
|
||||
/atom/movable/MouseEntered(location, control, params)
|
||||
. = ..()
|
||||
if(tooltips)
|
||||
if(!QDELETED(src) && usr.client.prefs.enable_tips)
|
||||
if(!QDELETED(src) && usr?.client.prefs.enable_tips)
|
||||
var/list/tooltip_data = get_tooltip_data()
|
||||
if(length(tooltip_data))
|
||||
var/examine_data = tooltip_data.Join("<br />")
|
||||
openToolTip(usr, src, params, title = name, content = examine_data)
|
||||
var/timedelay = max(usr.client.prefs.tip_delay * 0.01, 0.01) // I heard multiplying is faster, also runtimes from very low/negative numbers
|
||||
usr.client.tip_timer = addtimer(CALLBACK(GLOBAL_PROC, .proc/openToolTip, usr, src, params, name, examine_data), timedelay, TIMER_STOPPABLE)
|
||||
|
||||
/atom/movable/MouseExited(location, control, params)
|
||||
. = ..()
|
||||
@@ -150,3 +154,7 @@ Notes:
|
||||
/client/MouseDown(object, location, control, params)
|
||||
closeToolTip(usr)
|
||||
. = ..()
|
||||
|
||||
/client
|
||||
/// Timers are now handled by clients, not by doing a mess on the item and multiple people overwriting a single timer on the object, have fun.
|
||||
var/tip_timer = null
|
||||
|
||||
@@ -524,17 +524,6 @@
|
||||
<ul class="changes bgimages16">
|
||||
<li class="balance">Rod of asclepius can now be used for revival surgery</li>
|
||||
</ul>
|
||||
|
||||
<h2 class="date">07 August 2021</h2>
|
||||
<h3 class="author">BlueWildrose updated:</h3>
|
||||
<ul class="changes bgimages16">
|
||||
<li class="bugfix">The black dress, pink tutu, the bathrobe, the kimonos, and the qipaos no longer have a missing pixel when wearing them with the feminine bodytype. They're also no longer adjustable (they have no sprite for the adjusted variant and therefore it would just make an error if someone did that.)</li>
|
||||
</ul>
|
||||
<h3 class="author">Putnam3145 updated:</h3>
|
||||
<ul class="changes bgimages16">
|
||||
<li class="balance">Supernova rad storms are now half as likely per tick tweak: Supernovae don't announce they're ending if they never announced they're starting tweak: Supernovae say explicitly no rad storms can happen if they can't</li>
|
||||
<li class="rscadd">Monstermos is back</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<b>GoonStation 13 Development Team</b>
|
||||
|
||||
Reference in New Issue
Block a user