Scripts & Tutorials This forum is for scripts and code, as well as all kinds of tutorials, software, tools and so forth. Remember to give credit!
The thread revival limit does not apply here.

Reply
 
Thread Tools
  #76    
Old March 30th, 2017 (10:09 AM).
Mashirosakura's Avatar
Mashirosakura Mashirosakura is offline
     
    Join Date: Jan 2017
    Gender: Male
    Posts: 43
    Quote:
    Originally Posted by M3rein View Post
    Look at the error. Please. "isSurfableTag?".
    Hasn't fixed anything, sadly. I put it where the error was but there's still an issue.
    Reply With Quote

    Relevant Advertising!

      #77    
    Old March 31st, 2017 (6:55 AM).
    FL's Avatar
    FL FL is offline
    Pokémon Island Creator
       
      Join Date: Sep 2010
      Gender: Male
      Posts: 1,695
      Quote:
      Originally Posted by Mashirosakura View Post
      It fixed the initial activating surf animation issue. Now a new one has started, when I move in any direction in the water afterwards. I'll put an image below.
      I tested my tutorial again on V 16.2, even on bridges. The working code:

      Code:
      def canUseMoveSurf?
        if !$DEBUG &&
           !(HIDDENMOVESCOUNTBADGES ? $Trainer.numbadges>=BADGEFORSURF : $Trainer.badges[BADGEFORSURF])
          Kernel.pbMessage(_INTL("Sorry, a new Badge is required."))
          return false
        end
        if $PokemonGlobal.surfing
          Kernel.pbMessage(_INTL("You're already surfing."))
          return false
        end
        if $game_player.pbHasDependentEvents?
          Kernel.pbMessage(_INTL("It can't be used when you have someone with you."))
          return false
        end
        if pbGetMetadata($game_map.map_id,MetadataBicycleAlways)
          Kernel.pbMessage(_INTL("Let's enjoy cycling!"))
          return false
        end
        terrain=Kernel.pbFacingTerrainTag
        notCliff=$game_map.passable?($game_player.x,$game_player.y,$game_player.direction)
        if !PBTerrain.isSurfable?(terrain) || !notCliff
          Kernel.pbMessage(_INTL("No surfing here!"))
          return false
        end
        return true
      end
       
      def useMoveSurf
        $game_temp.in_menu=false
        if !pbHiddenMoveAnimation(nil)
          Kernel.pbMessage(_INTL("{1} used Surfboard!",$Trainer.name))
        end
        surfbgm=pbGetMetadata(0,MetadataSurfBGM)
        pbCueBGM(surfbgm,0.5) if surfbgm
        pbStartSurfing()
        return true
      end
      __________________
      Reply With Quote
        #78    
      Old April 1st, 2017 (2:48 AM).
      Mashirosakura's Avatar
      Mashirosakura Mashirosakura is offline
         
        Join Date: Jan 2017
        Gender: Male
        Posts: 43
        Quote:
        Originally Posted by FL View Post
        I tested my tutorial again on V 16.2, even on bridges. The working code:

        Code:
        def canUseMoveSurf?
          if !$DEBUG &&
             !(HIDDENMOVESCOUNTBADGES ? $Trainer.numbadges>=BADGEFORSURF : $Trainer.badges[BADGEFORSURF])
            Kernel.pbMessage(_INTL("Sorry, a new Badge is required."))
            return false
          end
          if $PokemonGlobal.surfing
            Kernel.pbMessage(_INTL("You're already surfing."))
            return false
          end
          if $game_player.pbHasDependentEvents?
            Kernel.pbMessage(_INTL("It can't be used when you have someone with you."))
            return false
          end
          if pbGetMetadata($game_map.map_id,MetadataBicycleAlways)
            Kernel.pbMessage(_INTL("Let's enjoy cycling!"))
            return false
          end
          terrain=Kernel.pbFacingTerrainTag
          notCliff=$game_map.passable?($game_player.x,$game_player.y,$game_player.direction)
          if !PBTerrain.isSurfable?(terrain) || !notCliff
            Kernel.pbMessage(_INTL("No surfing here!"))
            return false
          end
          return true
        end
         
        def useMoveSurf
          $game_temp.in_menu=false
          if !pbHiddenMoveAnimation(nil)
            Kernel.pbMessage(_INTL("{1} used Surfboard!",$Trainer.name))
          end
          surfbgm=pbGetMetadata(0,MetadataSurfBGM)
          pbCueBGM(surfbgm,0.5) if surfbgm
          pbStartSurfing()
          return true
        end
        It must be something on my end then, because I'm still getting the error with PBEndSurf
        Reply With Quote
        Reply
        Quick Reply

        Sponsored Links
        Thread Tools

        Posting Rules
        You may not post new threads
        You may not post replies
        You may not post attachments
        You may not edit your posts

        BB code is On
        Smilies are On
        [IMG] code is On
        HTML code is Off

        Forum Jump


        All times are GMT -8. The time now is 2:29 PM.