File: surround.gravitspawn

package info (click to toggle)
gravit 0.5.1%2Bdfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 10,420 kB
  • ctags: 942
  • sloc: ansic: 6,841; makefile: 63; sh: 43
file content (17 lines) | stat: -rw-r--r-- 548 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
-- vim:syntax=lua tabstop=4

load("functions.lua")

function describe()
    log("A positive mass group of particles surrounded by a negative mass group of particles")
end

function spawn()

        makegalaxy(v(0,0,0), v(0,0,0), randomfloat(1,1000), randomfloat(1, 1000), 0, 0, math.floor(spawnparticles/2))
    
        m = randomfloat(1, 2000)
        makeball(v(0,0,0), v(0,0,0), randomfloat(1000,10000), 0, randomfloat(1, m), 
                 math.floor(spawnparticles/2), spawnparticles - math.floor(spawnparticles/2))
	
end