I DID IT HOLY SHIT I GONE AND DONE IT
OnSecondaryUse is what throwing uses for doing things SPECIFICALLY on throw. This way, you can theoretically have grenades on which you'll have to pull the pin before throwing. This also lets flares be used without the need to throw them. did i mention my brain hurts
This commit is contained in:
@@ -165,15 +165,15 @@ namespace Barotrauma.Items.Components
|
||||
if (this.character == null || this.character != character || this.character.SelectedConstruction != item || !character.CanInteractWith(item))
|
||||
{
|
||||
character = null;
|
||||
return;
|
||||
return false;
|
||||
}
|
||||
if (character == null) return;
|
||||
if (character == null) return false;
|
||||
|
||||
Entity focusTarget = GetFocusTarget();
|
||||
if (focusTarget == null)
|
||||
{
|
||||
item.SendSignal(0, XMLExtensions.Vector2ToString(character.CursorWorldPosition), "position_out", character);
|
||||
return;
|
||||
return false;
|
||||
}
|
||||
|
||||
character.ViewTarget = focusTarget;
|
||||
@@ -191,6 +191,8 @@ namespace Barotrauma.Items.Components
|
||||
{
|
||||
item.SendSignal(0, XMLExtensions.Vector2ToString(character.CursorWorldPosition), "position_out", character);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
private Item GetFocusTarget()
|
||||
|
||||
Reference in New Issue
Block a user