Fix lathe animations
This commit is contained in:
@@ -99,11 +99,8 @@ namespace Content.Server.GameObjects.Components.Research
|
|||||||
}
|
}
|
||||||
|
|
||||||
internal bool Produce(LatheRecipePrototype recipe)
|
internal bool Produce(LatheRecipePrototype recipe)
|
||||||
{ if(!Powered)
|
{
|
||||||
{
|
if (Producing || !Powered || !CanProduce(recipe) || !Owner.TryGetComponent(out MaterialStorageComponent? storage)) return false;
|
||||||
return false;
|
|
||||||
}
|
|
||||||
if (Producing || !CanProduce(recipe) || !Owner.TryGetComponent(out MaterialStorageComponent? storage)) return false;
|
|
||||||
|
|
||||||
UserInterface?.SendMessage(new LatheFullQueueMessage(GetIdQueue()));
|
UserInterface?.SendMessage(new LatheFullQueueMessage(GetIdQueue()));
|
||||||
|
|
||||||
@@ -181,15 +178,21 @@ namespace Content.Server.GameObjects.Components.Research
|
|||||||
State = LatheState.Inserting;
|
State = LatheState.Inserting;
|
||||||
switch (material.MaterialTypes.Values.First().Name)
|
switch (material.MaterialTypes.Values.First().Name)
|
||||||
{
|
{
|
||||||
case "Steel":
|
case "steel":
|
||||||
SetAppearance(LatheVisualState.InsertingMetal);
|
SetAppearance(LatheVisualState.InsertingMetal);
|
||||||
break;
|
break;
|
||||||
case "Glass":
|
case "glass":
|
||||||
SetAppearance(LatheVisualState.InsertingGlass);
|
SetAppearance(LatheVisualState.InsertingGlass);
|
||||||
break;
|
break;
|
||||||
case "Gold":
|
case "gold":
|
||||||
SetAppearance(LatheVisualState.InsertingGold);
|
SetAppearance(LatheVisualState.InsertingGold);
|
||||||
break;
|
break;
|
||||||
|
case "plastic":
|
||||||
|
SetAppearance(LatheVisualState.InsertingPlastic);
|
||||||
|
break;
|
||||||
|
case "plasma":
|
||||||
|
SetAppearance(LatheVisualState.InsertingPlasma);
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
Owner.SpawnTimer(InsertionTime, () =>
|
Owner.SpawnTimer(InsertionTime, () =>
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
- type: material
|
- type: material
|
||||||
id: steel
|
id: steel
|
||||||
name: steel
|
name: steel
|
||||||
color: gray
|
color: gray
|
||||||
@@ -31,7 +31,7 @@
|
|||||||
- type: material
|
- type: material
|
||||||
id: gold
|
id: gold
|
||||||
name: gold
|
name: gold
|
||||||
icon: Objects/Materials/goldbar_single.png
|
icon: Objects/Materials/materials.rsi/goldbar_10.png
|
||||||
density: 10000
|
density: 10000
|
||||||
electricResistivity: 8.0e-9
|
electricResistivity: 8.0e-9
|
||||||
thermalConductivity: 30
|
thermalConductivity: 30
|
||||||
|
|||||||
Reference in New Issue
Block a user