21 lines
245 B
GDScript3
21 lines
245 B
GDScript3
|
extends Node
|
||
|
|
||
|
var items: Array
|
||
|
|
||
|
func _ready():
|
||
|
pass # Replace with function body.
|
||
|
|
||
|
|
||
|
func add_item (item):
|
||
|
if items.has(item):
|
||
|
return
|
||
|
|
||
|
items.append(item)
|
||
|
|
||
|
|
||
|
func contains_item (item):
|
||
|
return items.has(item)
|
||
|
|
||
|
|
||
|
func get_items ():
|
||
|
return items
|