diff options
author | Hugo Locurcio <hugo.locurcio@hugo.pro> | 2021-08-27 00:51:17 +0200 |
---|---|---|
committer | Hugo Locurcio <hugo.locurcio@hugo.pro> | 2021-08-27 00:51:17 +0200 |
commit | 60116b17b59c5e137924a9669ddc9bbe58a58ef7 (patch) | |
tree | edb9982ec21c2c48fad5b49837a5bcf7cdf1e5e4 /core/variant/array.h | |
parent | 98d55ba66f16ce5b5a5340c62a65865a45337aed (diff) |
Add an `Array.pop_at()` method to pop an element at an arbitrary index
Negative indices are supported to pop an element relative from the end.
Diffstat (limited to 'core/variant/array.h')
-rw-r--r-- | core/variant/array.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/core/variant/array.h b/core/variant/array.h index 540dcb1f4e..e9634ccece 100644 --- a/core/variant/array.h +++ b/core/variant/array.h @@ -97,6 +97,7 @@ public: void push_front(const Variant &p_value); Variant pop_back(); Variant pop_front(); + Variant pop_at(int p_pos); Array duplicate(bool p_deep = false) const; |