mirror of
https://github.com/jiojciojsioe3/a3cjroijsiojiorj.git
synced 2024-12-22 17:26:13 +08:00
block search when p2 is loading song
This commit is contained in:
parent
38963479bc
commit
b02dd02ad9
@ -257,6 +257,7 @@ class SongSelect{
|
||||
this.selectedSong = 0
|
||||
this.selectedDiff = 0
|
||||
this.lastCurrentSong = {}
|
||||
this.searchEnabled = true
|
||||
assets.sounds["bgm_songsel"].playLoop(0.1, false, 0, 1.442, 3.506)
|
||||
|
||||
if(!assets.customSongs && !fromTutorial && !("selectedSong" in localStorage) && !songId){
|
||||
@ -2855,6 +2856,9 @@ class SongSelect{
|
||||
}
|
||||
|
||||
displaySearch(fromButton=false){
|
||||
if(!this.searchEnabled){
|
||||
return
|
||||
}
|
||||
if(this.search){
|
||||
return this.removeSearch(true)
|
||||
}
|
||||
@ -3227,6 +3231,7 @@ class SongSelect{
|
||||
}
|
||||
|
||||
onusers(response){
|
||||
var p2InSong = false
|
||||
this.songs.forEach(song => {
|
||||
song.p2Cursor = null
|
||||
})
|
||||
@ -3252,11 +3257,18 @@ class SongSelect{
|
||||
if(this.state.screen !== "difficulty"){
|
||||
this.toSelectDifficulty({player: response.value.player})
|
||||
}
|
||||
this.searchEnabled = false
|
||||
p2InSong = true
|
||||
this.removeSearch()
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
if(!this.searchEnabled && !p2InSong){
|
||||
this.searchEnabled = true
|
||||
}
|
||||
}
|
||||
onsongsel(response){
|
||||
if(response && response.value){
|
||||
|
Loading…
Reference in New Issue
Block a user