forked from tgstation/tgstation
-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #22 from Bird-Lounge/Loadouts-Possibly
LOADOUT CATEGORIES
- Loading branch information
Showing
20 changed files
with
1,381 additions
and
1 deletion.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
/// Used to set custom descriptions. | ||
#define INFO_DESCRIBED "description" | ||
|
||
/// Max amonut of misc / backpack items that are allowed. | ||
#define MAX_ALLOWED_MISC_ITEMS 3 | ||
/// The maximum allowed amount of erp items allowed in any given character's loadout | ||
#define MAX_ALLOWED_ERP_ITEMS 7 | ||
|
||
/// Defines for extra info blurbs, for loadout items. | ||
#define TOOLTIP_NO_ARMOR "Armorless" | ||
#define TOOLTIP_NO_DAMAGE "CEREMONIAL - This item has very low force and is cosmetic." | ||
#define TOOLTIP_RANDOM_COLOR "Random Color" | ||
#define TOOLTIP_GREYSCALE "GREYSCALED - This item can be customized via the greyscale modification UI." | ||
#define TOOLTIP_RENAMABLE "RENAMABLE - This item can be given a custom name." | ||
|
||
#define LOADOUT_OVERRIDE_JOB "Delete job items" | ||
#define LOADOUT_OVERRIDE_BACKPACK "Move job to backpack" | ||
#define LOADOUT_OVERRIDE_CASE "Place all in case" |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
# LOADOUT CATEGORIES | ||
|
||
Most loadout categories are added in, if it is one that is stock TG just add in additional items in the respecitve files. | ||
|
||
If you need to add more categories or items the following format should be followed: | ||
|
||
## Format | ||
|
||
```DM | ||
/datum/loadout_category/<category name here> | ||
category_name = "<category name here>" | ||
category_ui_icon = FA_ICON_GLASSES // A Fontawesome icon to be used for the Category item | ||
type_to_generate = /datum/loadout_item/<category item here> | ||
tab_order = /datum/loadout_category/head::tab_order + 1 //This is where it will place the item in the tab order | ||
/datum/loadout_item/<category item here> | ||
abstract_type = /datum/loadout_item/glasses | ||
/datum/loadout_item/<category item here>/insert_path_into_outfit(datum/outfit/outfit, mob/living/carbon/human/equipper, visuals_only = FALSE) | ||
if(outfit.glasses) | ||
LAZYADD(outfit.backpack_contents, outfit.glasses) // This will dictate if the item will go into the backpack if the slot is already occupied | ||
outfit.glasses = item_path | ||
``` | ||
|
||
```DM | ||
/datum/loadout_item/pocket_items/<Logical name for the loadout item> | ||
name = "<Name that will show up in the loadout menu>" | ||
item_path = <The items actual path> | ||
/* Here there could be additional vars specified current list of possible vars as follows: | ||
restricted_roles // If the item is only allowed on specific roles I.E Security Items | ||
blacklisted_roles // If the item cannot be given to specific roles I.E. Prisoner | ||
restricted_species // If the item would cause issues with a species | ||
required_season = null // If the item is a seasonal one and should only show up then | ||
erp_item = FALSE // If the item is suggestive | ||
erp_box = FALSE // If the item is suggestive and should be put in a box | ||
/* | ||
``` | ||
|
||
## Helper Functions | ||
|
||
### Post equip Item | ||
|
||
`/datum/loadout_item/proc/post_equip_item` | ||
This proc particulalrly is useful if you wish for a specific item to do something after it gets equipped to the character. As an exapmple take the wallet, equip it on the ID card slot then just put the ID into the wallet so you dont have to put your own ID in your wallet. Useful for that sort of thing. | ||
|
||
### Pre equip Item | ||
|
||
`/datum/loadout_item/proc/pre_equip_item` | ||
Useful for doing checks on a item before it gets equipped for whatever reason, most of the time check to see if the slot would affect someone who has a item there they need to survive, I.E. Plasmamen. | ||
|
||
### Can be applied to | ||
|
||
`/datum/loadout_item/proc/can_be_applied_to` | ||
Checkes if the item passes requirements and isn't blacklisted based on role or species or restricted to specific role |
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,102 @@ | ||
/datum/loadout_category/belt | ||
category_name = "Belt" | ||
category_ui_icon = FA_ICON_SCREWDRIVER_WRENCH | ||
type_to_generate = /datum/loadout_item/belts | ||
tab_order = /datum/loadout_category/accessories::tab_order + 1 | ||
|
||
|
||
/* | ||
* LOADOUT ITEM DATUMS FOR THE BELT SLOT | ||
*/ | ||
/datum/loadout_item/belts | ||
abstract_type = /datum/loadout_item/belts | ||
|
||
/datum/loadout_item/belts/insert_path_into_outfit(datum/outfit/outfit, mob/living/carbon/human/equipper, visuals_only = FALSE) | ||
if(outfit.belt) | ||
LAZYADD(outfit.backpack_contents, outfit.belt) | ||
outfit.belt = item_path | ||
|
||
|
||
/datum/loadout_item/belts/fanny_pack_black | ||
name = "Black Fannypack" | ||
item_path = /obj/item/storage/belt/fannypack/black | ||
|
||
/datum/loadout_item/belts/fanny_pack_blue | ||
name = "Blue Fannypack" | ||
item_path = /obj/item/storage/belt/fannypack/blue | ||
|
||
/datum/loadout_item/belts/fanny_pack_brown | ||
name = "Brown Fannypack" | ||
item_path = /obj/item/storage/belt/fannypack | ||
|
||
/datum/loadout_item/belts/fanny_pack_cyan | ||
name = "Cyan Fannypack" | ||
item_path = /obj/item/storage/belt/fannypack/cyan | ||
|
||
/datum/loadout_item/belts/fanny_pack_green | ||
name = "Green Fannypack" | ||
item_path = /obj/item/storage/belt/fannypack/green | ||
|
||
/datum/loadout_item/belts/fanny_pack_orange | ||
name = "Orange Fannypack" | ||
item_path = /obj/item/storage/belt/fannypack/orange | ||
|
||
/datum/loadout_item/belts/fanny_pack_pink | ||
name = "Pink Fannypack" | ||
item_path = /obj/item/storage/belt/fannypack/pink | ||
|
||
/datum/loadout_item/belts/fanny_pack_purple | ||
name = "Purple Fannypack" | ||
item_path = /obj/item/storage/belt/fannypack/purple | ||
|
||
/datum/loadout_item/belts/fanny_pack_red | ||
name = "Red Fannypack" | ||
item_path = /obj/item/storage/belt/fannypack/red | ||
|
||
/datum/loadout_item/belts/fanny_pack_yellow | ||
name = "Yellow Fannypack" | ||
item_path = /obj/item/storage/belt/fannypack/yellow | ||
|
||
/datum/loadout_item/belts/fanny_pack_white | ||
name = "White Fannypack" | ||
item_path = /obj/item/storage/belt/fannypack/white | ||
|
||
/datum/loadout_item/belts/lantern | ||
name = "Lantern" | ||
item_path = /obj/item/flashlight/lantern | ||
|
||
/datum/loadout_item/belts/candle_box | ||
name = "Candle Box" | ||
item_path = /obj/item/storage/fancy/candle_box | ||
|
||
/datum/loadout_item/belts/champion | ||
name = "Champion's Belt" | ||
item_path = /obj/item/storage/belt/champion | ||
|
||
// HOLSTERS | ||
|
||
/datum/loadout_item/belts/holster_shoulders | ||
name = "Shoulder Holster" | ||
item_path = /obj/item/storage/belt/holster | ||
|
||
// USEFUL BELTS | ||
|
||
/datum/loadout_item/belts/medical | ||
name = "Medical Belt" | ||
item_path = /obj/item/storage/belt/medical | ||
|
||
/datum/loadout_item/belts/security | ||
name = "Security Belt" | ||
item_path = /obj/item/storage/belt/security | ||
|
||
/datum/loadout_item/belts/utility | ||
name = "Utility Belt" | ||
item_path = /obj/item/storage/belt/utility | ||
|
||
/datum/loadout_item/belts/utility/chief | ||
name = "Chief Engineer's Utility Belt" | ||
item_path = /obj/item/storage/belt/utility/chief | ||
|
||
/datum/loadout_item/belts/mining | ||
name = "Explorer's Webbing" | ||
item_path = /obj/item/storage/belt/mining |
Oops, something went wrong.