• Our software update is now concluded. You will need to reset your password to log in. In order to do this, you will have to click "Log in" in the top right corner and then "Forgot your password?".
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

[Scripting Question] Moon phases ability

32
Posts
8
Years
Hi
I was going to make a custom ability that each turn sets a random moon phase for the user pokémon, like the turn starts and then say: "The full moon is shining" or "The moon is a beautiful crescent", and then stores that information in a variable for later use in a move that does different things depending of which of the 4 phases of the moon, i've already made simple abilities before, but i don't know where to start with this one, maybe can someone help me? thanks!
 
220
Posts
13
Years
  • Seen Nov 29, 2021
I know probably less than you, but I would guess you just have the variable assigned after weather is checked?
You could generate a random number between... 0 and 3? Although simply cycling through the phases would make more logical sense, so...
Maybe if the variable's not set, set it to a random number then add 1 to that number after each turn, unless it's 3 in which case make it 0?
Not sure how you'd clear the variable after battle though.
 
32
Posts
8
Years
Yup, i did it! thanks for the idea, i made it simply cycling trough the phases as you said, but i still want to make it random, cuz strategy reasons.
 
Back
Top