Add custom Don
- Registered users can customise the colour of their Don and it will appear for other players - Bug fixes: - Add lyrics checkbox to admin page - 2P shows above "creative" or "with lyrics" labels - Prevent accidental alt and menu keyboard presses from triggering browser menus - Fixed mouse hitboxes on difficulty selection - Clean cached sounds and lyrics when another song is loading - Fixed debug jumping to the top-left of the screen when hidden - Fixed server volume not being applied to songs
This commit is contained in:
@@ -8,8 +8,16 @@ class Controller{
|
||||
this.touchEnabled = touchEnabled
|
||||
if(multiplayer === 2){
|
||||
this.snd = p2.player === 2 ? "_p1" : "_p2"
|
||||
this.don = p2.don || defaultDon
|
||||
}else{
|
||||
this.snd = multiplayer ? "_p" + p2.player : ""
|
||||
this.don = account.loggedIn ? account.don : defaultDon
|
||||
}
|
||||
if(this.snd === "_p2" && this.objEqual(defaultDon, this.don)){
|
||||
this.don = {
|
||||
body_fill: defaultDon.face_fill,
|
||||
face_fill: defaultDon.body_fill
|
||||
}
|
||||
}
|
||||
|
||||
this.calibrationMode = selectedSong.folder === "calibration"
|
||||
@@ -317,6 +325,14 @@ class Controller{
|
||||
return this.mekadon.play(circle)
|
||||
}
|
||||
}
|
||||
objEqual(a, b){
|
||||
for(var i in a){
|
||||
if(a[i] !== b[i]){
|
||||
return false
|
||||
}
|
||||
}
|
||||
return true
|
||||
}
|
||||
clean(){
|
||||
if(this.multiplayer === 1){
|
||||
this.syncWith.clean()
|
||||
|
||||
Reference in New Issue
Block a user