Remove
Removes every occurrence of a value from a list and returns a new list. Removing a value that is not a member is a no-op: the original list is returned unchanged, and no error is raised.
Category: List
Returns: list
Signature
Remove(list, value)
The first argument is a list-typed variable. The second is the value to remove.
Examples
These are typed into the Value field of a Set Variable event whose Variable picker targets the same list:
Remove(var_inventory, "item_key") // spend a key from inventory
Remove(var_party, "char_kim") // Kim leaves the party
Remove(var_flags, "met_merchant") // forget the merchant encounter
Remove(var_inventory, "item_shield") // no-op: the shield wasn't there
Notes
The value must be a quoted string literal, or a variable that holds one, same as Add.
Remove drops every matching entry, not just the first. In practice this rarely matters: because Add never creates a duplicate, a list built only through Add and Remove never holds the same value twice to begin with. Matching is case-sensitive, same as Has.