diff --git a/etc/art/floatingbrick/diffuse.png b/etc/art/floatingbrick/diffuse.png new file mode 100644 index 0000000..4c5928d Binary files /dev/null and b/etc/art/floatingbrick/diffuse.png differ diff --git a/etc/art/floatingbrick/floatingbrick.blend b/etc/art/floatingbrick/floatingbrick.blend new file mode 100644 index 0000000..8392c16 Binary files /dev/null and b/etc/art/floatingbrick/floatingbrick.blend differ diff --git a/etc/art/floatingbrick/studs.png b/etc/art/floatingbrick/studs.png new file mode 100644 index 0000000..f4ce4dc Binary files /dev/null and b/etc/art/floatingbrick/studs.png differ diff --git a/etc/textureconverter/from.bat b/etc/textureconverter/from.bat new file mode 100644 index 0000000..9a06f95 --- /dev/null +++ b/etc/textureconverter/from.bat @@ -0,0 +1 @@ +magick convert plastic.png -channel rgba -alpha on -separate -swap 3,0 -combine -channel Alpha -evaluate set 255 +channel -channel Blue -evaluate set 255 +channel output.png \ No newline at end of file diff --git a/etc/textureconverter/plastic.png b/etc/textureconverter/plastic.png new file mode 100644 index 0000000..9dc08e5 Binary files /dev/null and b/etc/textureconverter/plastic.png differ diff --git a/web/public/models/graphictoriapart.glb b/web/public/models/graphictoriapart.glb new file mode 100644 index 0000000..cdc5975 Binary files /dev/null and b/web/public/models/graphictoriapart.glb differ diff --git a/web/resources/js/pages/Maintenance.js b/web/resources/js/pages/Maintenance.js index 5448158..38643be 100644 --- a/web/resources/js/pages/Maintenance.js +++ b/web/resources/js/pages/Maintenance.js @@ -1,16 +1,16 @@ // © XlXi 2021 // Graphictoria 5 -import React, { useRef } from 'react'; +import React, { useRef, Suspense } from 'react'; import { Canvas, useFrame } from '@react-three/fiber'; -import { Instances, Instance, PerspectiveCamera } from '@react-three/drei' +import { Instances, Instance, PerspectiveCamera, useGLTF } from '@react-three/drei'; -import SetTitle from "../Helpers/Title.js"; +import SetTitle from '../Helpers/Title.js'; const randomVector = (r) => [r / 2 - Math.random() * r, r / 2 - Math.random() * r, r / 2 - Math.random() * r]; const randomEuler = () => [Math.random() * Math.PI, Math.random() * Math.PI, Math.random() * Math.PI]; -const randomData = Array.from({ length: 500 }, (r = 100) => ({ random: Math.random(), position: randomVector(r), rotation: randomEuler() })); +const randomData = Array.from({ length: 500 }, (r = 200) => ({ random: Math.random(), position: randomVector(r), rotation: randomEuler() })); let Buttons = []; let ButtonsAlreadyTemplated = false; @@ -20,7 +20,7 @@ function MakeButtons() if(!ButtonsAlreadyTemplated) { ButtonsAlreadyTemplated = true; - let name = "Graphictoria"; + let name = 'Graphictoria'; for (var i = 0; i < name.length; i++) { Buttons.push({id: i, value: name.charAt(i)}); @@ -33,6 +33,25 @@ function DoButton(position) console.log(position); } +function Scene() { + const { nodes, materials } = useGLTF('/models/graphictoriapart.glb'); + + return ( + <> + + + + { + randomData.map((props, i) => ( + + )) + } + + + + ); +} + function Box({ random, ...props }){ const ref = useRef() useFrame((state) => { @@ -72,23 +91,14 @@ class Maintenance extends React.Component { <>
- - - - - - { - randomData.map((props, i) => ( - - )) - } - - + + +

Graphictoria is currently under maintenance.

-

Our advanced cyborg team of code-monkes are working to make Graphictoria better. We'll be back soon!

+

Our cyborg team of highly trained code-monkes are working to make Graphictoria better. We'll be back soon!

{