void Parcels_ParcelInfoReply(object sender, ParcelInfoReplyEventArgs e) { if (currentPick.ParcelID != e.Parcel.ID) { return; } if (InvokeRequired) { BeginInvoke(new MethodInvoker(() => Parcels_ParcelInfoReply(sender, e))); return; } lock (parcelCache) { if (!parcelCache.ContainsKey(e.Parcel.ID)) { parcelCache.Add(e.Parcel.ID, e.Parcel); } } pickLocation.Text = string.Format("{0}, {1} ({2}, {3}, {4})", e.Parcel.Name, currentPick.SimName, ((int)currentPick.PosGlobal.X) % 256, ((int)currentPick.PosGlobal.Y) % 256, ((int)currentPick.PosGlobal.Z) % 256 ); }
private void Parcels_OnParcelInfoReply(object sender, ParcelInfoReplyEventArgs e) { if (InvokeRequired) { BeginInvoke(new MethodInvoker(() => Parcels_OnParcelInfoReply(sender, e))); return; } if (pickUUID != e.Parcel.ID) { return; } this.BeginInvoke(new MethodInvoker(delegate() { parcelname = e.Parcel.Name; simname = e.Parcel.SimName; posX = (int)e.Parcel.GlobalX % 256; posY = (int)e.Parcel.GlobalY % 256; posZ = (int)e.Parcel.GlobalZ % 256; txtSlurl.Text = parcelname + ", " + simname + "(" + posX.ToString(CultureInfo.CurrentCulture) + "," + posY.ToString(CultureInfo.CurrentCulture) + "," + posZ.ToString(CultureInfo.CurrentCulture) + ")"; })); }
void Parcels_ParcelInfoReply(object sender, ParcelInfoReplyEventArgs e) { if (e.Parcel.ID != parcelID) { return; } if (InvokeRequired) { if (!instance.MonoRuntime || IsHandleCreated) { BeginInvoke(new MethodInvoker(() => Parcels_ParcelInfoReply(sender, e))); } return; } this.parcel = e.Parcel; pnlDetail.Visible = true; if (parcel.SnapshotID != UUID.Zero) { SLImageHandler img = new SLImageHandler(instance, parcel.SnapshotID, ""); img.Dock = DockStyle.Fill; pnlDetail.Controls.Add(img); pnlDetail.Disposed += (object senderx, EventArgs ex) => { img.Dispose(); }; img.BringToFront(); } btnTeleport.Enabled = true; btnShowOnMap.Enabled = true; if (parcelLocation) { localPosition = new Vector3(); localPosition.X = parcel.GlobalX % 256; localPosition.Y = parcel.GlobalY % 256; localPosition.Z = parcel.GlobalZ; } if (decodedLandmark == null) { txtParcelName.Text = string.Format("{0} - {1} ", parcel.Name, parcel.SimName); } else { txtParcelName.Text = string.Format("{0} - {1} ({2}, {3}, {4}) ", parcel.Name, parcel.SimName, (int)decodedLandmark.Position.X, (int)decodedLandmark.Position.Y, (int)decodedLandmark.Position.Z); } txtParcelDescription.Text = parcel.Description; }
void Parcels_ParcelInfoReply(object sender, ParcelInfoReplyEventArgs e) { if (e.Parcel.ID != parcelID) { return; } if (InvokeRequired) { if (!instance.MonoRuntime || IsHandleCreated) { BeginInvoke(new MethodInvoker(() => Parcels_ParcelInfoReply(sender, e))); } return; } parcel = e.Parcel; pnlDetail.Visible = true; if (parcel.SnapshotID != UUID.Zero) { SLImageHandler img = new SLImageHandler(instance, parcel.SnapshotID, "") { Dock = DockStyle.Fill }; pnlDetail.Controls.Add(img); pnlDetail.Disposed += (senderx, ex) => { img.Dispose(); }; img.BringToFront(); } btnTeleport.Enabled = true; btnShowOnMap.Enabled = true; if (parcelLocation) { localPosition = new Vector3 { X = parcel.GlobalX % 256, Y = parcel.GlobalY % 256, Z = parcel.GlobalZ }; } txtParcelName.Text = decodedLandmark == null ? $"{parcel.Name} - {parcel.SimName} " : $"{parcel.Name} - {parcel.SimName} ({(int) decodedLandmark.Position.X}, {(int) decodedLandmark.Position.Y}, {(int) decodedLandmark.Position.Z}) "; txtParcelDescription.Text = parcel.Description; }
public override void Parcels_OnParcelInfo(object sender, ParcelInfoReplyEventArgs e) { var parcel = e.Parcel; SimRegion r = SimRegion.GetRegion(parcel.SimName, client); if (r != null) { r.Parcels_OnParcelInfo(parcel); } else { base.Parcels_OnParcelInfo(sender, e); } }
private void Land_OnParcelInfoReply(object sender, ParcelInfoReplyEventArgs e) { client.Parcels.ParcelInfoReply -= new EventHandler <ParcelInfoReplyEventArgs>(Land_OnParcelInfoReply); landconsole.DisplayPlace(e.Parcel); }
void Parcels_ParcelInfoReply(object sender, ParcelInfoReplyEventArgs e) { }