diff options
-rw-r--r-- | not/Menu.lua | 6 | ||||
-rw-r--r-- | not/MusicPlayer.lua | 4 | ||||
-rw-r--r-- | not/World.lua | 6 |
3 files changed, 8 insertions, 8 deletions
diff --git a/not/Menu.lua b/not/Menu.lua index 8ef1861..cd6d963 100644 --- a/not/Menu.lua +++ b/not/Menu.lua @@ -38,7 +38,7 @@ Menu = { Menu.__index = Menu -require "not.Music" +require "not.MusicPlayer" function Menu:new (name) local o = setmetatable({}, self) @@ -54,7 +54,7 @@ function Menu:new (name) end function Menu:init (name) - self.music = Music:new("menu.ogg") + self.music = MusicPlayer("menu.ogg") self:open(name) end @@ -141,4 +141,4 @@ function Menu:controlreleased (set, action, key) for _,element in pairs(self.elements) do element:controlreleased(set, action, key) end -end
\ No newline at end of file +end diff --git a/not/MusicPlayer.lua b/not/MusicPlayer.lua index 1e65e3b..84f5384 100644 --- a/not/MusicPlayer.lua +++ b/not/MusicPlayer.lua @@ -1,4 +1,4 @@ -require "not.object" +require "not.Object" --- `MusicPlayer` -- Simple music player object that plays and loops selected track. @@ -22,7 +22,7 @@ function MusicPlayer:setTrack (trackName) if MusicPlayer.TRACKS[trackName] then self.source = MusicPlayer.TRACKS[trackName] else - local source = love.audio.newSource("assets/music" .. trackName) + local source = love.audio.newSource("assets/music/" .. trackName) source:setLooping(true) source:setVolume(.7) self.source = source diff --git a/not/World.lua b/not/World.lua index 99f50fa..112846a 100644 --- a/not/World.lua +++ b/not/World.lua @@ -26,7 +26,7 @@ require "not.Cloud" require "not.Effect" require "not.Decoration" require "not.Ray" -require "not.Music" +require "not.MusicPlayer" -- Constructor of `World` ZA WARUDO! function World:new (map, nauts) @@ -46,7 +46,7 @@ function World:new (map, nauts) self:loadMap(map) self:spawnNauts(nauts) self.camera = Camera:new(self) - self.music = Music:new(self.map.theme) + self.music = MusicPlayer(self.map.theme) end -- The end of the world @@ -402,4 +402,4 @@ function World:controlreleased (set, action, key) for k,naut in pairs(self:getNautsAll()) do naut:controlreleased(set, action, key) end -end
\ No newline at end of file +end |