Date: 2025/06/13 06:48:12 UTC-07:00
Type: Denizen Script
n_points_on_sphere:
type: task
script:
- define origin:<player.location.with_y[<player.location.y.add[50]>].with_x[<player.location.x.add[40]>]>
- define diameter:0.5
- define samples:5000
- define phi:<element[5].sqrt.sub[1].mul[<util.pi>]>
- repeat <[samples]> as:n:
- define y:<[n].div[<element[<[samples]>]>].mul[2].sub[1]>
- define radius:<element[1].sub[<[y].mul[<[y]>]>].sqrt>
- define theta:<[phi].mul[<[n]>]>
- define x:<[theta].cos.mul[<[radius]>]>
- define z:<[theta].sin.mul[<[radius]>]>
- define loc:<[origin].add[<location[<[x].mul[<[diameter]>]>,<[y].mul[<[diameter]>]>,<[z].mul[<[diameter]>]>,<[origin].world>]>]>
- push block_display[material=stone;gravity=false] origin:<[loc]> destination:<[loc].add[<[origin].face[<[loc]>].direction.vector.mul[50]>]> speed:0.5 no_rotate