Commit Graph

6 Commits

Author SHA1 Message Date
Pieter-Jan Briers
ed1a96e536 Nullability fixes. 2020-08-20 16:48:15 +02:00
Víctor Aguilera Puerto
c3df108b27 Stripping (#1668)
* Start work on stripping.

* more strippable work

* Stripping works

* Nullable

* MORE NULLABLE

* nullable moment

* life is pain

* Interaction check.

* Update Content.Client/GameObjects/Components/HUD/Inventory/StrippableBoundUserInterface.cs

Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>

* Update Content.Client/GameObjects/Components/HUD/Inventory/StrippableBoundUserInterface.cs

Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>

* Update Content.Server/GameObjects/Components/GUI/HandsComponent.cs

Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>

* Update Content.Server/GameObjects/Components/GUI/HandsComponent.cs

Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>

* Update Content.Server/GameObjects/Components/GUI/HandsComponent.cs

Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>

* Update Content.Server/GameObjects/Components/GUI/StrippableComponent.cs

Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>

* Update Content.Server/GameObjects/Components/GUI/StrippableComponent.cs

Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>

* Update Content.Server/GameObjects/Components/GUI/HandsComponent.cs

Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>

* Update Content.Server/GameObjects/Components/GUI/StrippableComponent.cs

Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>

* Update Content.Server/GameObjects/Components/GUI/StrippableComponent.cs

Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>

* Update Content.Shared/GameObjects/Components/GUI/SharedStrippableComponent.cs

Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>

* Update Content.Server/GameObjects/Components/GUI/StrippableComponent.cs

Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>

* Rename InventoryComponent and HandsComponent's OnChanged event to OnItemChanged

* Apply suggestions from code review

Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>

* Use static EquipmentSlotDefines

* Do not expose ContainerSlot on Inventory or Hands.

Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>
2020-08-15 20:33:42 +02:00
DrSmugleaf
00d5effcb8 Fix addhand command (#1519) 2020-07-28 15:38:23 +02:00
DrSmugleaf
c57b1c2914 Fix inhands not displaying (#1517) 2020-07-28 02:53:36 -07:00
DrSmugleaf
0a82aba88e Add pulling (#1409)
* Initial framework for pulling.

* Make it possible to pull items via (temporary) keybind Ctrl+Click, make items follow the player correctly.

* Make other objects pullable, implement functionality for moving an object being pulled, make only one object able to be pulled at a time.

* Make sure that MoveTo won't allow collisions with the player

* Update everything to work with the new physics engine

* Update Content.Server/GameObjects/EntitySystems/Click/InteractionSystem.cs

Co-authored-by: ComicIronic <comicironic@gmail.com>

* Physics update and convert to direct type casts

* Add notnull checks

* Add pull keybinds to the tutorial window

* Move PullController to shared

* Fix pulled items getting left behind

* Fix moving pulled objects into walls

* Remove flooring of coordinates when moving pulled objects

* Add missing null check in PutInHand

* Change pulling keybind to control and throwing to alt

* Change PhysicsComponent references to IPhysicsComponent

* Add trying to pull a pulled entity disabling the pull

* Add pulled status effect

* Fix merge conflicts

* Merge fixes

* Make players pullable

* Fix being able to pull yourself

* Change pull moving to use a velocity

* Update pulled and pulling icons to not be buckle

A tragedy

* Make pulled and pulling icons more consistent

* Remove empty not pulled and not pulling images

* Pulled icon update

* Pulled icon update

* Add clicking pulling status effect to stop the pull

* Fix spacewalking when pulling

* Merge conflict fixes

* Add a pull verb

* Fix nullable error

* Add pulling through the entity drop down menu

Co-authored-by: Jackson Lewis <inquisitivepenguin@protonmail.com>
Co-authored-by: ComicIronic <comicironic@gmail.com>
2020-07-27 00:54:32 +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