diff --git a/binaries/data/config/system.cfg b/binaries/data/config/system.cfg index 4e193a26b8..350c22e905 100755 --- a/binaries/data/config/system.cfg +++ b/binaries/data/config/system.cfg @@ -1,5 +1,5 @@ novbo=true -shadows=false +shadows=true vsync=false ; You can specify these as well, but the default (keeping the current resolution) is diff --git a/binaries/data/mods/official/entities/templates/Deciduous Tree 1.xml b/binaries/data/mods/official/entities/templates/Deciduous Tree 1.xml index 53eb178607..7962165fb7 100755 --- a/binaries/data/mods/official/entities/templates/Deciduous Tree 1.xml +++ b/binaries/data/mods/official/entities/templates/Deciduous Tree 1.xml @@ -5,7 +5,6 @@ Deciduous 1 0 - scripts/pasap/initdude scripts/pasap/tick diff --git a/binaries/data/mods/official/entities/templates/Deciduous Tree 2.xml b/binaries/data/mods/official/entities/templates/Deciduous Tree 2.xml index 67b7ac1007..51b13d7443 100755 --- a/binaries/data/mods/official/entities/templates/Deciduous Tree 2.xml +++ b/binaries/data/mods/official/entities/templates/Deciduous Tree 2.xml @@ -4,6 +4,6 @@ Deciduous Tree 2 Deciduous 2 0 + - \ No newline at end of file diff --git a/binaries/data/mods/official/entities/templates/Prometheus Dude.xml b/binaries/data/mods/official/entities/templates/Prometheus Dude.xml index ffb0d4a0b3..e5e84ff1af 100755 --- a/binaries/data/mods/official/entities/templates/Prometheus Dude.xml +++ b/binaries/data/mods/official/entities/templates/Prometheus Dude.xml @@ -8,4 +8,6 @@ 2.5 2.0 + GOTO + PATROL diff --git a/binaries/data/mods/official/gui/test/hello.xml b/binaries/data/mods/official/gui/test/hello.xml index 40e0097ed8..bf45cdcbc9 100755 --- a/binaries/data/mods/official/gui/test/hello.xml +++ b/binaries/data/mods/official/gui/test/hello.xml @@ -13,6 +13,47 @@ writeConsole("Dude created at " + DudeSpawnPoint); } + function updateOrbital() + { + if( !getGUIObjectByName( 'arena' ).hidden ) + { + writeConsole( "Updating..." ); + g_ballx += g_balldx; + g_bally += g_balldy; + if (g_ballx > 600) { + g_balldx *= -0.9; + g_ballx = 600-(g_ballx-600); + } + else if (g_ballx < 0) { + g_balldx *= -0.9; + g_ballx = -g_ballx; + } + if (g_bally > 400) { + g_balldy *= -0.9; + g_bally = 400-(g_bally-400); + } + else if (g_bally < 0) { + g_balldy *= -0.9; + g_bally = -g_bally; + } + + // Gravitate towards the mouse + var vect_x = g_ballx-g_mousex; + var vect_y = g_bally-g_mousey; + var dsquared = vect_x*vect_x + vect_y*vect_y; + if (dsquared < 1000) dsquared = 1000; + var force = 10000.0 / dsquared; + var mag = Math.sqrt(dsquared); + vect_x /= mag; vect_y /= mag; + g_balldx -= force * vect_x; + g_balldy -= force * vect_y; + + var ball = getGUIObjectByName('ball'); + var r=5; + ball.size = new GUISize(g_ballx-r, g_bally-r, g_ballx+r, g_bally+r); + } + } + writeConsole("Made MakeDude " + MakeDude); ]]> @@ -62,42 +103,14 @@ Nunc bibendum metus a tellus. Nulla lorem metus, convallis id, lobortis eu, elem g_bally = 200; g_balldx = 0; g_balldy = 0; + g_mousex = 0; + g_mousey = 0; + setInterval( updateOrbital, 100 ); ]]> 600) { - g_balldx *= -0.9; - g_ballx = 600-(g_ballx-600); - } - else if (g_ballx < 0) { - g_balldx *= -0.9; - g_ballx = -g_ballx; - } - if (g_bally > 400) { - g_balldy *= -0.9; - g_bally = 400-(g_bally-400); - } - else if (g_bally < 0) { - g_balldy *= -0.9; - g_bally = -g_bally; - } - - // Gravitate towards the mouse - var vect_x = g_ballx-mouse.x; - var vect_y = g_bally-mouse.y; - var dsquared = vect_x*vect_x + vect_y*vect_y; - if (dsquared < 1000) dsquared = 1000; - var force = 10000.0 / dsquared; - var mag = Math.sqrt(dsquared); - vect_x /= mag; vect_y /= mag; - g_balldx -= force * vect_x; - g_balldy -= force * vect_y; - - var ball = getGUIObjectByName('ball'); - var r=5; - ball.size = new GUISize(g_ballx-r, g_bally-r, g_ballx+r, g_bally+r); + g_mousex = mouse.x; + g_mousey = mouse.y; ]]>