-- message for players
rules = function()
    Trigger.AfterDelay(DateTime.Seconds(1320), function()
        Media.PlaySound("laugh.aud")
    end)
    Trigger.AfterDelay(DateTime.Seconds(1500), function()
        Media.PlaySound("laugh.aud")
    end)
    Trigger.AfterDelay(DateTime.Seconds(1600), function()
        Media.PlaySound("laugh.aud")
    end)
    Trigger.AfterDelay(DateTime.Seconds(1700), function()
        Media.PlaySound("laugh.aud")
    end)
    Trigger.AfterDelay(DateTime.Seconds(702), function()
        Media.PlaySound("laugh.aud")
    end)
    Trigger.AfterDelay(DateTime.Seconds(1800), function()
        Media.PlaySound("laugh.aud")
    end)
    Trigger.AfterDelay(DateTime.Seconds(1803), function()
        Media.PlaySound("laugh.aud")
    end)
    Trigger.AfterDelay(DateTime.Seconds(1805), function()
        Media.PlaySound("laugh.aud")
    end)
    Trigger.AfterDelay(DateTime.Seconds(1905), function()
        Media.PlaySound("laugh.aud")
    end)
    Trigger.AfterDelay(DateTime.Seconds(2005), function()
        Media.PlaySound("laugh.aud")
    end)
    Trigger.AfterDelay(DateTime.Seconds(1), function()
        Media.DisplayMessage ("Loading background noise, hang on...", "Pacman", HSLColor.Red)
        Trigger.AfterDelay(DateTime.Seconds(3), function()
            Media.PlaySound("war.aud")
            Trigger.AfterDelay(DateTime.Seconds(3), function()
                Media.DisplayMessage ("Welcome to the WW3 mod v2.0.6", "Waggy", HSLColor.Red)
                Trigger.AfterDelay(DateTime.Seconds(8), function()
                    Media.DisplayMessage ("Make Pacman President!", "Clyde", HSLColor.Brown)
                    Trigger.AfterDelay(DateTime.Seconds(12), function()
                        Media.DisplayMessage ("BuildTimeSpeedReduction: 100, 80, 67, 55, 45, 37, 30, 25, 21, 18, 16, 14, 12, 10", "Militairy Advisor", HSLColor.Blue)
                        Trigger.AfterDelay(DateTime.Seconds(16), function()
                            Media.DisplayMessage ("Special thanks to the map creator & ERCC creators. GLHF!", "Waggy", HSLColor.Green)
                            Trigger.AfterDelay(DateTime.Seconds(130), function()
                                Media.PlaySound("output.aud")
                                Trigger.AfterDelay(DateTime.Seconds(5), function()
                                    Media.PlaySound("war.aud")
                                    Trigger.AfterDelay(DateTime.Seconds(130), function()
                                        Media.PlaySound("output.aud")
                                        Trigger.AfterDelay(DateTime.Seconds(5), function()
                                            Media.PlaySound("war.aud")
                                            Trigger.AfterDelay(DateTime.Seconds(130), function()
                                                Media.PlaySound("laugh.aud")
                                                Trigger.AfterDelay(DateTime.Seconds(5), function()
                                                    Media.PlaySound("kill.aud")
                                                    Trigger.AfterDelay(DateTime.Seconds(130), function()
                                                        Media.PlaySound("war.aud")
                                                    end)
                                                end)
                                            end)
                                        end)
                                    end)
                                end)
                            end)
                        end)
                    end)
                end)
            end)
        end)
    end)
end

-- load world
WorldLoaded = function ()
    player = Player.GetPlayer("Multi0")
    rules()
end

Tick = function ()

end