Custom burgers - FoodSequence system (#30755)

* setup foodsequence

* name generation and max layers limit

* move to nutrition

* move code to serverside

* move to appearance data

* marked fields as required

* Update foodsequence.yml

* b

* burgeers!

* Update produce.yml

* Update meat.yml

* Update burger.yml

* fix duplicate naming

* Update Resources/Locale/en-US/nutrition/components/food-sequence.ftl

Co-authored-by: Hrosts <35345601+Hrosts@users.noreply.github.com>

* merge flavor profiles

* make food trash List<>

* merge trash

* Update FoodComponent.cs

* Update FoodComponent.cs

* organs and cannabis support

---------

Co-authored-by: Hrosts <35345601+Hrosts@users.noreply.github.com>
This commit is contained in:
Ed
2024-08-10 22:31:32 +03:00
committed by GitHub
parent 707daa1a5e
commit 4d75cb54c8
34 changed files with 1358 additions and 61 deletions

View File

@@ -125,18 +125,21 @@ namespace Content.Server.Nutrition.EntitySystems
if (ev.Cancelled)
return;
if (string.IsNullOrEmpty(foodComp.Trash))
if (foodComp.Trash.Count == 0)
{
QueueDel(uid);
return;
}
// Locate the sliced food and spawn its trash
var trashUid = Spawn(foodComp.Trash, _xformSystem.GetMapCoordinates(uid));
foreach (var trash in foodComp.Trash)
{
var trashUid = Spawn(trash, _xformSystem.GetMapCoordinates(uid));
// try putting the trash in the food's container too, to be consistent with slice spawning?
_xformSystem.DropNextTo(trashUid, uid);
_xformSystem.SetLocalRotation(trashUid, 0);
// try putting the trash in the food's container too, to be consistent with slice spawning?
_xformSystem.DropNextTo(trashUid, uid);
_xformSystem.SetLocalRotation(trashUid, 0);
}
QueueDel(uid);
}