• Just a reminder that providing specifics on, sharing links to, or naming websites where ROMs can be accessed is against the rules. If your post has any of this information it will be removed.
  • Ever thought it'd be cool to have your art, writing, or challenge runs featured on PokéCommunity? Click here for info - we'd love to spotlight your work!
  • Dawn, Gloria, Juliana, or Summer - which Pokémon protagonist is your favorite? Let us know by voting in our poll!
  • 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] New zodiac powers of a sort giving errors

#Not Important

All hail the wishmaker
  • 905
    Posts
    5
    Years
    So, I made a new gimmick for my game called 'spirit powers' , I have it all running apart from the actual gimmick.
    You click 'z' when in a battle and the conditions are right.
    BUT

    I keep getting a syntax error on line 285 (opp1.pbReduceHP((opp1.totalhp/2).floor)
    if you would like to see how I set it all out (I have made the line giving me problems bold) here it is:
    Spoiler:

    I didn't end the PokeBattle_Battle class because I have some more rewrites below it

    Thanks in advance!Thanks in advance!
     
    Looking at the code, you seem to be missing a parenthesis on the line just above it.
     
    Code:
    opp1.pbReduceHP = ((opp1.totalhp/2).floor

    It should be:
    Code:
    opp1.pbReduceHP((opp1.totalhp/2).floor)
    #Bracket after 'floor' was missing. Also pbReduceHP is a function so you don't put an = sign after calling it on opp1
     
    It should be:
    Code:
    opp1.pbReduceHP((opp1.totalhp/2).floor)
    #Bracket after 'floor' was missing. Also pbReduceHP is a function so you don't put an = sign after calling it on opp1

    I fixed that just now :)
    I'll try yours tho

    EDIT* It does not work :(
     
    Back
    Top