Commit Graph

59 Commits

Author SHA1 Message Date
Swept
6eeaa58988 HandheldLights no longer drain their batteries in 20 seconds. (#2942)
* Initial

* Update Content.Server/GameObjects/Components/Interactable/HandheldLightComponent.cs

Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
2021-01-07 21:35:39 +11:00
metalgearsloth
482106e827 Optimise handheld lights (#2927)
* Optimise handheld lights

* Woops also these

* Might as well do shutdown too

* Also these

Co-authored-by: Metal Gear Sloth <metalgearsloth@gmail.com>
2021-01-06 12:50:49 +01:00
DrSmugleaf
fcd52fa90c Add ActionBlockerExtensions 2020-12-20 04:26:21 +01:00
chairbender
7a3c281f60 Actions System + UI (#2710)
Co-authored-by: Vera Aguilera Puerto <6766154+Zumorica@users.noreply.github.com>
2020-12-13 23:28:20 +01:00
Alex Evgrashin
fb6dd4a490 Working flashlight for hard hats (#2599)
* Add verb to toggle flashlight

* Playing with hand-held light for hard hat

* ClothingEquippedPrefix will update players sprite when changed

* Make abstract prototype for hardhat and fixed hardhat orange sprites

* Fixed all other hard hats

* Fixed requested changes

* Restore prototype and sprites changes

* Nullables

* That's actually nullable

Co-authored-by: Metal Gear Sloth <metalgearsloth@gmail.com>
2020-11-23 14:17:38 +11:00
metalgearsloth
2e65b1e5fa Optimise flashlights (#2468)
Flashlights were calling dirty EVERY TICK so this just means they only call it when absoluetely necessary which saves a lot.

Co-authored-by: Metal Gear Sloth <metalgearsloth@gmail.com>
2020-10-31 21:56:46 +01:00
Peter Wedder
fca556a1c1 Adds sized (S, M, L) power cells and a generic component for battery powered items (#2352)
* Refactor battery/powercell assets and add new ones.

* committing before I fuck things up

* slot component doned I think

* dictionary update

* Fixes

* Moving flashlight to powerslotcomponent

* har har i am using the message tubes

* Better documentation comment

* Reverting this overengineered garbage.

* Off with ye I said

* Examine texts.

* Some minor fixes to IDE complaints

* slot size from yaml

* Ignored component + removing a useless typo entry

* Making stunbatons use this

* Handle the message and remove some unnecessary dirtiness

* actionblocker checks

* remove unused file

* remove updatevisual

* make these nullable

* make these nullable too

* Unrename sprite folder

* check itemcomponent on insertion

* Use SendMessage over Owner.SendMessage

* Add support for auto-recharging batteries, an auto-recharging cell, and make flashlight status update correctly if one is inserted in it.

* get rid of public fields which are Bad

* add a description for the stun baton while i'm in here

* one more public field

* Add the blinky animation to the atomic cell

* Fix the charge indicator being STUPID

* better comments

* this is a better function

* add pause for flashlight, remove unnecessary imports from battery

* potato battery copyright link

* WHO DID THAT

* mr clean has come

* Random pitch

* pausing

* round to nearest levels
2020-10-29 19:17:03 +01:00
RemberBL
5d4ad5f150 Fixed flashlights staying enabled after taking the battery out of them (#2158)
* Fixed flashlights staying enabled after taking the battery out of them

* Refactored code for flashlights shutting off after the battery is removed

* Fixed casing in makeNoise
2020-10-04 18:10:33 +02:00
DrSmugleaf
48b61f6bcc Replace every usage of GridCoordinates with EntityCoordinates (#2021)
* Update RobustToolbox

* Transition direct type usages

* More updates

* Fix invalid use of to map

* Update RobustToolbox

* Fix dropping items

* Rename name usages of "GridCoordinates" to "EntityCoordinates"

* Revert "Update RobustToolbox"

This reverts commit 9f334a17c5908ded0043a63158bb671e4aa3f346.

* Revert "Update RobustToolbox"

This reverts commit 3a9c8cfa3606fa501aa84407796d2ad920853a09.

# Conflicts:
#	RobustToolbox

* Fix cursed IMapGrid method usage.

* GridTileLookupTest now uses EntityCoordinates

Co-authored-by: Víctor Aguilera Puerto <6766154+Zumorica@users.noreply.github.com>
Co-authored-by: Víctor Aguilera Puerto <zddm@outlook.es>
2020-09-06 16:11:53 +02:00
DrSmugleaf
8f9ed2f562 Replace usages of ISharedNotifyManager and IServerNotifyManager with extension methods (#1965)
* Replace usages of ISharedNotifyManager and IServerNotifyManager with extension methods

* Remove redundant code
2020-09-01 12:34:53 +02:00
DrSmugleaf
5a0f7d9316 Add missing localization to verb names (#1953) 2020-08-29 13:36:02 +02:00
SoulSloth
df823d2245 Add Flashlight Visualizer/states (#1861)
* Add art assets for cloning

* Added a 'Scan DNA' button to the medical scanner

* Made the UI update unconditional for the medical scanner until checks for power changes are in place

* Update Medical scanner to reflect powered status and fix #1774

* added a 'scan dna' button the the medical scanner that will add the contained bodies Uid to a list in CloningSystem, fixed an issue with the menu not populating if the scanner starts in an unpowered state

* Add disabling logic to 'Scan DNA' button on medical scanner

* Removed un-used libraries

* Added playing parameter to radiatingLightComponent, changed it's animation key to radiatingLight

* refactored RadiatingLight into a visualizer

* Added different light animations for differnt power states of a flashlight

* split out the radiating light visualizer into two seperate visualizers

* further refactored and tweaked handheldlight animations

* further lantern light tweaks

* removed un-used attributes in flashlight and lantern prototypes

* fix null check in handheldlightcomponent
2020-08-24 12:32:18 +02:00
DrSmugleaf
814daaba4c Fix the flashlight's power bar and status with no battery (#1862)
Co-authored-by: Víctor Aguilera Puerto <6766154+Zumorica@users.noreply.github.com>
2020-08-23 13:19:40 +02:00
DrSmugleaf
a4a25a9975 Remove localization manager dependencies from components (#1864)
Co-authored-by: Víctor Aguilera Puerto <6766154+Zumorica@users.noreply.github.com>
2020-08-23 12:53:09 +02:00
DrSmugleaf
b9196d0a10 Add a test that puts all components on an entity and checks for no exceptions (#1815)
* Add test that puts all components on an entity and checks for no exceptions

Also fix all the exceptions that happened because of this

* Add comments to the test

* Fix nullable errors

* Fix more nullable errors

* More nullable error fixes

* Unignore basic actor component

* Fix more nullable errors

* NULLABLE ERROR

* Add string interpolation

* Merge if checks

* Remove redundant pragma warning disable 649

* Address reviews

* Remove null wrappers around TryGetComponent

* Merge conflict fixes

* APC battery component error fix

* Fix power test

* Fix atmos mapgrid usages
2020-08-22 22:29:20 +02:00
Julian Giebel
259762717b Change cell that spawns with flashlights (#1781)
Co-authored-by: Julian Giebel <j.giebel@netrocks.info>
2020-08-18 19:33:24 +02:00
Víctor Aguilera Puerto
d9ae942759 Make InteractUsing async, make tools use DoAfter. (#1772)
* Make IInteractUsing async, make tools use DoAfter.

* Disable warning 1998 in Content.Server

* Update Content.Server/GameObjects/Components/AnchorableComponent.cs
2020-08-18 14:39:08 +02:00
DrSmugleaf
4a8ed41e3a Fix namespaces and optimize imports (#1651)
* Fix namespaces and optimize imports

* Cleanup fixes

* Merge conflict fixes

* Merge conflict fixes

* Merge conflict fixes
2020-08-13 14:40:27 +02:00
DrSmugleaf
4b4e83d2bf Add changing the amount of hands on the GUI depending on your body parts (#1406)
* Multiple hands in gui first pass

* Remove IHandsComponent interface

* Create hand class and more hand textures

* Refactor ServerHandsComponent to use a single list of hands

* Seal SharedHand

* Fix picked up items not showing on top of the hand buttons

* Remove HandsGui buttons and panels dictionaries

* Fix items in hands rendering

* Fix wrong hand container comparison

* Fix not updating the location of duplicate hands

* Change ClientHandsComponent to use a SortedList instead of a dictionary

* More merge conflict fixes

* Change SortedList to List

* Fix hand button order

* Add item tooltip for more than 2 hands and updating when removing hands

* Add add hand and remove hand command

* Merge conflict fixes

* Remove nullable reference type from ContainerSlot

* Fix texture errors

* Fix error when reaching 0 hands

* Fix error when swapping hands with no hands

* Merged remove hand methods

* Fix item panel texture errors

* Merge conflict fixes

* Fix addhand and removehand command descriptions

* Add properly displaying tooltips for 2 hands

* Make hand indexes and locations consistent across the client and server

* Add dropping held entity if a hand is removed

* Change hand location to be calculated by index

* Made different hand gui updates more consistent

* Remove human body yml testing changes

* Sanitize addhand and removehand commands

* Merge conflict fixes

* Remove testing changes

* Revert body system changes

* Add missing imports

* Remove obsolete hands parameter in yml files

* Fix broken import

* Fix startup error and adding and removing hands on the same tick

* Make hand container id use an uint

In case someone gets more than 2 billion hands

* Rename hand component files

* Make hands state use an array
2020-07-25 15:11:16 +02:00
Acruid
ea94f4a182 Moved interaction interfaces from Server to Shared. 2020-07-18 22:51:56 -07:00
DrSmugleaf
8f685f0541 Merge branch 'master' into buckle-locker-fix-1262 2020-07-07 20:36:43 +02:00
AJCM-git
ae41d03ec6 Re-organizing the Resources folder. Part 1. (#1234)
* First commit

* Lockers

* Lockers electric boogaloo

* Crates and Lockers

* Almost finishing the Textures folder

* Updating texture paths. Reminder to fix:
* Lockers
* Windows
* Vending Machines
* APC
* Catwalks
* Bedsheets and Cloaks
* Status effects

* dont know what happened here

* Commit before merge

* re-organizing

* Lockers broken

* Commit before merge

* Submodule

* renaming

* Fixing most issues

* forgot these ones

* Updating submodule

* typo

* Fixing some paths

* fixing some paths

* updating submodule

* (hopefully) fixing the submodule
2020-07-07 19:19:00 +02:00
DrSmugleaf
7cc5a3fb65 Merge conflict fixes 2020-07-07 00:23:41 +02:00
DrSmugleaf
b850ac2437 Merge branch 'master' into buckle-locker-fix-1262 2020-07-07 00:20:07 +02:00
chairbender
b35333d366 Click Drag Functionality + Refactor Interaction Interfaces (#1125)
Co-authored-by: Víctor Aguilera Puerto <6766154+Zumorica@users.noreply.github.com>
Co-authored-by: ComicIronic <comicironic@gmail.com>
Co-authored-by: Pieter-Jan Briers <pieterjan.briers+git@gmail.com>
2020-07-06 23:27:03 +02:00
DrSmugleaf
81647d696e Disable interactions for entities in storage 2020-07-03 23:57:19 +02:00
py01
23cc6b1d4e Power Rework (#863)
Co-authored-by: py01 <pyronetics01@gmail.com>
2020-06-28 17:23:26 +02:00
Swept
bad7f9dc6b Lots of new inhands, adds phoron (#1220)
* Beaker Inhands

* Flashlight Inhands

* Tile Refactor

* Adds metal/glass sheet inhands

* Removes plasma

* Adds Phoron

* We boolin'

* Phoron inhands

* First Pass inhand food

* First food inhand pass

* Soda inhand sprites

* Actually adds them
2020-06-25 13:51:58 +02:00
Pieter-Jan Briers
f3a816321c Merge branch 'master' into 20-06-24-movement-prediction 2020-06-24 04:04:43 +02:00
DrSmugleaf
ff0f082138 Fix being able to use invalid verbs as a ghost (#1157)
* Add CanInteract check to 18 verbs

* Add more caninteract checks to verbs without it

Storage toggle open, ammo box dump, bolt open and close, revolver spin and magazine open and close
2020-06-22 18:54:56 +02:00
Memory
21c41f28ed Refactor all references to AudioSystem functions now that the old ones are obsolete. (#1081)
Co-authored-by: FL-OZ <anotherscuffed@gmail.com>
2020-06-07 15:55:15 +02:00
Remie Richards
2e38c194f7 IExamine can now limit certain details behind a 'details' range check. (#1039)
* IExamine can now limit certain details behind a 'details' range check.

* Comic's Review fixes.
- colour -> color. My ancestors are saddened by this.
- Can see wire panel opened/closed at any distance again.
2020-05-31 20:29:06 +02:00
Víctor Aguilera Puerto
a9a43f25ce Remove unused IEntitySystemManager dependencies. 2020-05-31 19:58:49 +02:00
FL-OZ
53900b79e9 Rename SoundComponent and refactor its wrong usages. (#1036)
* Rename `SoundComponent` and refactor its wrong usages.

* Replace verbose IoC grabs with EntitySysetm.Get

* unused depend

Co-authored-by: FL-OZ <anotherscuffed@gmail.com>
Co-authored-by: Víctor Aguilera Puerto <6766154+Zumorica@users.noreply.github.com>
2020-05-31 19:40:36 +02:00
Clyybber
1ad9a10050 Fix #274 (#927) 2020-05-23 17:23:25 +02:00
chairbender
6a4d78cfac Add interaction checks to all interactions (#923) 2020-05-23 11:27:31 +02:00
Pieter-Jan Briers
cad59d2cb4 Fancy Verb Menu & Verb API Refactor (#928) 2020-05-23 03:09:44 +02:00
Pieter-Jan Briers
9c0a670525 Fix flashlights not updating status when battery inserted. 2020-01-12 02:02:58 +01:00
Pieter-Jan Briers
92da411ea5 Flashlight wattag is now a VV-able variable. 2020-01-12 02:01:00 +01:00
Pieter-Jan Briers
411c23c46e Item status! 2020-01-09 00:28:04 +01:00
Acruid
1fe09c580c Entities now require a location when being spawned. 2019-12-16 21:44:24 -08:00
Ephememory
1f177a044d Fix flashlight PointLight radius (#438)
* Add radius to `HandheldLightComponent.cs`

* Revert handheldlightcomponent and simply specify radius to flashlight in yaml.
2019-11-21 15:23:09 +01:00
Pieter-Jan Briers
fd109436e5 Localize & fancify all the examine tooltips with markup. 2019-10-13 22:49:07 +02:00
Pieter-Jan Briers
cf97ef7ad1 Give flashlights feedback about dead/missing cell. 2019-10-10 11:50:53 +02:00
Pieter-Jan Briers
ceb8cc8421 Use automatic component registration. 2019-07-31 15:07:54 +02:00
Pieter-Jan Briers
1132e5b6a7 Update submodule: light cleanup. 2019-07-30 13:31:46 +02:00
Pieter-Jan Briers
930cb61af8 Flashlight improvements:
1. Sound effects
2. fixed sprite having a hole
2019-07-27 11:56:36 +02:00
Acruid
d52e5ccbfb Verbs can now set themselves as invisible. 2019-05-22 08:53:50 -07:00
Pieter-Jan Briers
e35d5390db Storage system refactor & map init.
* Demonstrated map init working with guns, toolboxes, tool lockers.
* Refactored EntityStorage and ServerStorage to have a common interface.
* EntityStorage no longer uses ServerStorage PURELY for visuals.
  Use an appearance visualizer instead.
2019-05-05 18:52:06 +02:00
Silver
a18692bc46 Rename toolbox references from ss14 to robust 2019-04-15 21:11:38 -06:00