mirror of
https://github.com/godotengine/godot-demo-projects.git
synced 2025-12-31 09:49:06 +03:00
Remove unnecessary randomize() (#862)
Seed is now automatically randomized on startup in Godot 4.
This commit is contained in:
@@ -24,8 +24,6 @@ class Bullet:
|
||||
|
||||
|
||||
func _ready():
|
||||
randomize()
|
||||
|
||||
shape = PhysicsServer2D.circle_shape_create()
|
||||
# Set the collision shape's radius for each bullet in pixels.
|
||||
PhysicsServer2D.shape_set_data(shape, 8)
|
||||
|
||||
@@ -3,10 +3,6 @@ extends Node
|
||||
@export var mob_scene: PackedScene
|
||||
var score
|
||||
|
||||
func _ready():
|
||||
randomize()
|
||||
|
||||
|
||||
func game_over():
|
||||
$ScoreTimer.stop()
|
||||
$MobTimer.stop()
|
||||
|
||||
@@ -65,7 +65,6 @@ func _on_peers_pressed():
|
||||
|
||||
|
||||
func _on_ping_pressed():
|
||||
randomize()
|
||||
ping.rpc(randf())
|
||||
|
||||
|
||||
|
||||
@@ -5,7 +5,6 @@ extends Node3D
|
||||
# To use, attach this script to the "Walls" node.
|
||||
|
||||
func _ready():
|
||||
randomize()
|
||||
var walls = get_tree().get_nodes_in_group("walls")
|
||||
for wall in walls:
|
||||
var material = StandardMaterial3D.new()
|
||||
|
||||
Reference in New Issue
Block a user