RealEthanPlayzDev / StarGenerator

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

StarGenerator

Generated by Rojo 7.0.0.

Roblox module for generating stars.

Usage

function StarGenerator.Generate(count: number, posdef: posv3 | posnumber, acolors: {Color3}, folder: Instance, size: Vector3?)

Used to generate stars.

  • count: number = Amount of stars
  • posdef: posv3 | posnumber = (See the types definition)
  • acolors: {Color3}? = An array filled with Color3s to override default colors (optional)
  • folder: Instance? = Optional place to parent the stars into
  • size: Vector3 = Optional star size

type posv3 = {pos1=Vector3, pos2=Vector3?}

  • pos1: Vector3 = Main vector of the position for randomisation
  • pos2: Vector3 = Optional, second vector, if not defined then the positions will be randomised between -pos1 and pos1 else it will be randomised between pos1 and pos2

type posnumber = {pos1: number, pos2: number?, minheight: number?, maxheight: number?}

  • pos1: number = Main number position for randomisation
  • pos2: number? = Optional, second number position for randomisation, if not defined then the positions will be randomised between -pos1 and pos1, else it will be randomised between pos1 and pos2
  • minheight: number? = Optional, minimum height of star generation for randomisation
  • maxheight: number? = Optional, maximum height of star generation for randomisation

Note that if minheight or maxheight are not defined, height will always be at 500 studs

ALL NUMBERS SHOULD BE CONSIDERED IN STUDS

About

License:GNU General Public License v3.0


Languages

Language:Lua 96.7%Language:Makefile 3.3%