mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-07-04 07:22:19 +02:00
stellar handling for revelation dance
This commit is contained in:
parent
3766dce68e
commit
1ba35b5c20
@ -2178,9 +2178,15 @@ export class MatchUserTypeAttr extends VariableMoveTypeAttr {
|
||||
apply(user: Pokemon, target: Pokemon, move: Move, args: any[]): boolean {
|
||||
const type = (args[0] as Utils.IntegerHolder);
|
||||
|
||||
const userTypes = user.getTypes();
|
||||
const userTypes = user.getTypes(true);
|
||||
console.log(userTypes)
|
||||
|
||||
if (userTypes && userTypes.length > 0) {
|
||||
if(userTypes && userTypes.length > 0 && userTypes.includes(Type.STELLAR)) { // will not change to stellar type
|
||||
const nonTeraTypes = user.getTypes();
|
||||
type.value = nonTeraTypes[0];
|
||||
return true;
|
||||
}
|
||||
else if (userTypes && userTypes.length > 0) {
|
||||
type.value = userTypes[0];
|
||||
return true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user