Librarian gameplay (DND, but in SS14) (#17041)
* D&D character sheets * Tabletop improvements * Grass battlemap * You can now put shit inside of the board * change variable name * make the grass tabletop better, again * update the damn thing AGAIN * update the shit AGAIN * You can now take stuff out of tabletops * Make it use parenting to avoid zany bugs * MORE battlemaps! Battlemaps for everyone! * You can now dump out pieces + cleanup * All (most) non-game pieces should fall to the ground * make the verb a bit more responsive * Librarian content officially done * fix tests i think * i forgot the sheet * Smidgen of refactoring * You can no longer put high risk items inside of boards * no boardgame defusal * minor refactoring * hoplogrma * doc * fix rt
This commit is contained in:
@@ -44,8 +44,9 @@ namespace Content.Client.Tabletop
|
||||
UpdatesOutsidePrediction = true;
|
||||
|
||||
CommandBinds.Builder
|
||||
.Bind(EngineKeyFunctions.Use, new PointerInputCmdHandler(OnUse, false, true))
|
||||
.Register<TabletopSystem>();
|
||||
.Bind(EngineKeyFunctions.Use, new PointerInputCmdHandler(OnUse, false, true))
|
||||
.Bind(EngineKeyFunctions.UseSecondary, new PointerInputCmdHandler(OnUseSecondary, true, true))
|
||||
.Register<TabletopSystem>();
|
||||
|
||||
SubscribeNetworkEvent<TabletopPlayEvent>(OnTabletopPlay);
|
||||
SubscribeLocalEvent<TabletopDraggableComponent, ComponentHandleState>(HandleComponentState);
|
||||
@@ -177,6 +178,17 @@ namespace Content.Client.Tabletop
|
||||
_ => false
|
||||
};
|
||||
}
|
||||
private bool OnUseSecondary(in PointerInputCmdArgs args)
|
||||
{
|
||||
if (_draggedEntity != null && _table != null)
|
||||
{
|
||||
var ev = new TabletopRequestTakeOut();
|
||||
ev.Entity = _draggedEntity.Value;
|
||||
ev.TableUid = _table.Value;
|
||||
RaiseNetworkEvent(ev);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
private bool OnMouseDown(in PointerInputCmdArgs args)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user