mirror of
https://gitea.wildfiregames.com/0ad/0ad
synced 2026-07-06 23:15:47 -07:00
Add scripted HFSM system. Add very basic animal AI. Support script-only message types. Add shift+D hotkey to toggle dev command panel. This was SVN commit r7763.
9 lines
209 B
JavaScript
9 lines
209 B
JavaScript
/**
|
|
* Returns a random integer from min (inclusive) to max (exclusive)
|
|
*/
|
|
function RandomInt(min, max)
|
|
{
|
|
return Math.floor(min + Math.random() * (max-min))
|
|
}
|
|
|
|
Engine.RegisterGlobal("RandomInt", RandomInt);
|