Script - Splash Screen: Difference between revisions

Wanderer (talk | contribs)
m fixed due change in scripting
m I guess the missing word was "time"...
Line 1: Line 1:
==Function==
==Function==
Randomizes the splash screen instead of showing the same picture every the game is started.
Randomizes the splash screen instead of showing the same picture every time the game is started.
*Splash screen images must be named Preloadxx (x is value from 0 to 99)
*Splash screen images must be named Preloadxx (x is value from 0 to 99)



Revision as of 21:53, 9 March 2009

Function

Randomizes the splash screen instead of showing the same picture every time the game is started.

  • Splash screen images must be named Preloadxx (x is value from 0 to 99)

Table Entry

#Global hooks
$Splash: [
	random_number = ma.getRandomNumber(0, 99)
	if gr.getScreenWidth() < 1024 then
		gr.drawImage("PreLoad" .. random_number, 0, 0)
	else
		gr.drawImage("2_PreLoad" .. random_number, 0, 0)
	end
]
	+Override: true
#End