protected virtual bool OnObjectPlacement(ObjectPlacementEventArgs e) { Contract.Requires <ArgumentNullException>(e != null); try { if (this.ObjectPlacement != null) { this.ObjectPlacement(this, e); } } catch (Exception ex) { this.ReportEventHandlerException("ObjectPlacement", ex); } return(e.Handled); }
protected virtual bool OnObjectPlacement(ObjectPlacementEventArgs e) { if (e == null) { throw new ArgumentNullException(); } try { if (this.ObjectPlacement != null) { this.ObjectPlacement(this, e); } } catch (Exception ex) { this.ReportEventHandlerException("ObjectPlacement", ex); } this.WriteHadnlerDebugInfo("ObjectPlacement", e); return(e.Handled); }
private void Net_ObjectPlacement(object sender, ObjectPlacementEventArgs e) { if (this.isDisposed || !this.hooksEnabled || e.Handled) return; if (this.UserInteractionHandler.HandleObjectPlacement(e.Player, e.BlockType, e.Location, e.ObjectStyle)) { e.Handled = true; return; } e.Handled = this.WorldMetadataHandler.HandleObjectPlacement(e.Player, e.BlockType, e.Location, e.ObjectStyle); }
protected virtual bool OnObjectPlacement(ObjectPlacementEventArgs e) { Contract.Requires<ArgumentNullException>(e != null); try { if (this.ObjectPlacement != null) this.ObjectPlacement(this, e); } catch (Exception ex) { this.ReportEventHandlerException("ObjectPlacement", ex); } return e.Handled; }
private void Net_ObjectPlacement(object sender, ObjectPlacementEventArgs e) { if (this.isDisposed || !this.hooksEnabled || e.Handled) return; e.Handled = this.UserInteractionHandler.HandleObjectPlacement(e.Player, e.Location, (int)e.BlockType, e.ObjectStyle, e.Alternative, e.Random, e.Direction); }