var loot = ["sword", "shield", "potion"]
var drop = loot.pick_random()
Shuffle in place with loot.shuffle(), and roll numbers with randi_range(1, 6) or randf_range(0.0, 1.0).
Weighted picks need a little more (Godot 4.3+):
var rng = RandomNumberGenerator.new()
var weights = PackedFloat32Array([70, 25, 5])
var index = rng.rand_weighted(weights)
var drop = loot[index]
Godot seeds the global generator for you on startup. For a reproducible run (daily challenge, replays), call seed(12345) once at the start.