-
Notifications
You must be signed in to change notification settings - Fork 67
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
I See Clearly Now: Laser pointer balance adjustments (#1173)
* Laser pointer fixes: remove felinid forced movement, chat notifications, add limited laser pointer type * Comment formatting fixes * Trailing formatting fix * Modularise * Make GCF vendor sell limited laserpointers * Apply suggestions from code review --------- Co-authored-by: Ephemeralis <[email protected]> Co-authored-by: Bloop <[email protected]>
- Loading branch information
1 parent
01313cc
commit 6801cdd
Showing
5 changed files
with
50 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
37 changes: 37 additions & 0 deletions
37
modular_skyrat/master_files/code/game/objects/items/devices/laserpointer.dm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
/obj/item/laser_pointer | ||
//Whether the laser pointer is capable of receiving upgrades | ||
var/upgradable = TRUE | ||
|
||
/obj/item/laser_pointer/limited | ||
//limited laser pointers cannot receive upgrades, mostly used in loadout | ||
upgradable = FALSE | ||
|
||
/obj/item/laser_pointer/limited/red | ||
pointer_icon_state = "red_laser" | ||
|
||
/obj/item/laser_pointer/limited/green | ||
pointer_icon_state = "green_laser" | ||
|
||
/obj/item/laser_pointer/limited/blue | ||
pointer_icon_state = "blue_laser" | ||
|
||
/obj/item/laser_pointer/limited/purple | ||
pointer_icon_state = "purple_laser" | ||
|
||
/obj/item/laser_pointer/screwdriver_act(mob/living/user, obj/item/tool) | ||
if(!upgradable) | ||
balloon_alert(user, "can't remove integrated diode!") | ||
return | ||
return ..() | ||
|
||
/obj/item/laser_pointer/attackby(obj/item/attack_item, mob/user, params) | ||
if(istype(attack_item, /obj/item/stock_parts/micro_laser) || istype(attack_item, /obj/item/stack/ore/bluespace_crystal)) | ||
if(!upgradable) | ||
balloon_alert(user, "can't upgrade integrated parts!") | ||
return | ||
return ..() | ||
|
||
/obj/item/laser_pointer/examine(mob/user) | ||
. = ..() | ||
if(!upgradable) | ||
. += span_notice("The diode and the lens are both cheap, integrated components. This pointer cannot be upgraded.") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters