new command SetParcelSnapshot

This commit is contained in:
Madpeter 2025-06-04 15:46:50 +01:00
parent 164e464f04
commit 56f40daf37

View file

@ -875,6 +875,28 @@ namespace SecondBotEvents.Commands
return BasicReply("ok", [amount]); return BasicReply("ok", [amount]);
} }
[About("Sets the current parcels snapshot")]
[ReturnHints("ok")]
[ReturnHintsFailure("Error not in a sim")]
[ReturnHintsFailure("Parcel data not ready")]
[ReturnHintsFailure("Invaild texture uuid")]
[ArgHints("texture", "The texture uuid to set as the snapshot", "UUID")]
public object SetParcelSnapshot(string texture)
{
KeyValuePair<bool, string> tests = SetupCurrentParcel();
if (tests.Key == false)
{
return Failure(tests.Value);
}
if (UUID.TryParse(texture, out UUID textureuuid) == false)
{
return Failure("Invaild texture uuid", [texture]);
}
targetparcel.SnapshotID = textureuuid;
targetparcel.Update(GetClient());
return BasicReply("ok", [texture]);
}
[About("Freezes an avatar")] [About("Freezes an avatar")]
[ReturnHints("ok")] [ReturnHints("ok")]
[ReturnHintsFailure("Invaild avatar UUID")] [ReturnHintsFailure("Invaild avatar UUID")]