File tree Expand file tree Collapse file tree 1 file changed +25
-0
lines changed
Code/MethodSystem/Methods/PickupMethods Expand file tree Collapse file tree 1 file changed +25
-0
lines changed Original file line number Diff line number Diff line change 1+ using LabApi . Features . Wrappers ;
2+ using Mirror ;
3+ using SER . Code . ArgumentSystem . Arguments ;
4+ using SER . Code . ArgumentSystem . BaseArguments ;
5+ using SER . Code . MethodSystem . BaseMethods ;
6+ using SER . Code . MethodSystem . MethodDescriptors ;
7+ using SER . Code . ValueSystem ;
8+
9+ namespace SER . Code . MethodSystem . Methods . PickupMethods ;
10+
11+ public class PickupExistsMethod : ReturningMethod < BoolValue >
12+ {
13+ public override string Description => "Returns true if the provided pickup is still present on the server." ;
14+
15+ public override Argument [ ] ExpectedArguments { get ; } =
16+ [
17+ new ReferenceArgument < Pickup > ( "pickup reference" )
18+ ] ;
19+
20+ public override void Execute ( )
21+ {
22+ var pickup = Args . GetReference < Pickup > ( "pickup reference" ) ;
23+ ReturnValue = NetworkServer . spawned . ContainsValue ( pickup . NetworkIdentity ) ;
24+ }
25+ }
You can’t perform that action at this time.
0 commit comments