mirror of
https://github.com/oliverbooth/VpSharp
synced 2024-11-10 02:35:42 +00:00
Use ternary for vp_query_cell
This works because CA wanted us to capture the return var, which we are just discarding. VP sometimes you are cursed but in a good way
This commit is contained in:
parent
9f16e6cc77
commit
189ef770eb
@ -33,14 +33,9 @@ public sealed partial class VirtualParadiseClient
|
||||
|
||||
lock (Lock)
|
||||
{
|
||||
if (revision is not null)
|
||||
{
|
||||
vp_query_cell_revision(NativeInstanceHandle, cell.X, cell.Z, revision.Value);
|
||||
}
|
||||
else
|
||||
{
|
||||
vp_query_cell(NativeInstanceHandle, cell.X, cell.Z);
|
||||
}
|
||||
_ = revision is not null
|
||||
? vp_query_cell_revision(NativeInstanceHandle, cell.X, cell.Z, revision.Value)
|
||||
: vp_query_cell(NativeInstanceHandle, cell.X, cell.Z);
|
||||
}
|
||||
|
||||
return channel.Reader.ReadAllAsync();
|
||||
@ -106,7 +101,7 @@ public sealed partial class VirtualParadiseClient
|
||||
lock (Lock)
|
||||
{
|
||||
_ = vp_int_set(NativeInstanceHandle, IntegerAttribute.ReferenceNumber, id);
|
||||
reason = (ReasonCode) vp_object_get(NativeInstanceHandle, id);
|
||||
reason = (ReasonCode)vp_object_get(NativeInstanceHandle, id);
|
||||
if (reason != ReasonCode.Success)
|
||||
{
|
||||
goto PreReturn;
|
||||
|
Loading…
Reference in New Issue
Block a user