Advertisement
pixeljp

random

Jul 31st, 2023
918
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. extends Node2D
  2.  
  3. #only the first two show up and the other two dont
  4.  
  5. func _ready():
  6.     if randi() % 3 == 0:
  7.         $TextureRect.texture = load("res://Hot AirballoonNew.png")
  8.     elif randi() % 2 == 0:
  9.         $TextureRect.texture = load("res://hotairballoon new2.png")
  10.     elif randi() % 1 == 0:
  11.         $TextureRect.texture = load("res://hotairballoon new3.png")
  12.     else:
  13.         $TextureRect.texture = load("res://hotairballoon new4.png")
  14.  
  15.  
  16.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement