feat: General.compareTurntime
This commit is contained in:
@@ -155,4 +155,21 @@ export class General extends LazyEntityUpdater<IGeneralEntity> {
|
||||
|
||||
}
|
||||
|
||||
public compareTurntime(other: General): number {
|
||||
if(this._raw.turntime < other._raw.turntime){
|
||||
return -1;
|
||||
}
|
||||
if(this._raw.turntime > other._raw.turntime){
|
||||
return 1;
|
||||
}
|
||||
|
||||
if(this._raw.id < other._raw.id){
|
||||
return -1;
|
||||
}
|
||||
if(this._raw.id > other._raw.id){
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user