private HandZone GetHandZone(SabberStoneCore.Model.Zones.HandZone zone) { var result = new HandZone(); var span = zone.GetSpan(); for (int i = 0; i < span.Length; i++) { result.Entities.Add(GetPlayable(span[i], true)); } return(result); }
public HandZone(SabberZones.HandZone zone) { var playables = new Playable[10]; var span = zone.GetSpan(); for (int i = 0; i < span.Length; i++) { playables[i] = new Playable(span[i], true); } Count = span.Length; Playables = playables; }
public HandZone_unmanaged(SabberZones.HandZone zone) { var span = zone.GetSpan(); Count = span.Length; int size = Marshal.SizeOf <Playable>(); IntPtr playables = Marshal.AllocHGlobal(size * Count); IntPtr ptr = playables; for (int i = 0; i < span.Length; i++) { Marshal.StructureToPtr(new Playable(span[i], true), ptr, false); ptr += size; } Playables = playables; }
private HandZone(Controller c, HandZone zone) : base(c, zone) { Type = Zone.HAND; }
private HandZone(Controller c, HandZone zone) : base(c, zone) { }