Announcement

Collapse
No announcement yet.

How to find rapid fire code for any game for ps2?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    You're asking for an example of a recursive function in a game? I don't think I can really do that for you. Recursion is one of those things that's a godsend when you need it, but 99.9% of the time you don't. If you're going to find recursion in a game, it would be something of a unicorn hunt in the high-level code. My guess is that you'd be more likely to find it in lower-level routines for rendering and media playback, but if there's a consistent need for recursion even at that level, it's likely to be encapsulated in drivers or on the hardware.

    The main reason is that true recursion requires the function to call itself, and the recursive calls continue to whatever depth is required. Then the whole thing bubbles back up to the original call. This is time-consuming and can be relatively costly in terms of system resources, which isn't good for a game. They have some large number of things they have to do in each game tick/frame, and waiting a recursive chain to complete can easily eat up too many cycles. Games typically function as "state machines", and break tasks down into units of what's required each frame. So if there actually was a task that might ordinarily lend itself well to recursion, it would probably be broken up into enough states to cover the worst case scenario of the game, and some part of it would be handled in each tick.

    A decay function for a sound effect might be a good example of something a game could conceivably handle recursively, but you'd have to look at the audio hardware. Even in the PS 1 days, that was something you requested from the SPU. If the SPU in some way does it recursively through software, it doesn't affect the game engine so much because a purpose-built piece of hardware is handling it. I'm about 90% sure that's all handled on the metal, though.

    In general computing terms, the go-to example of recursion is computing a factorial, e.g., 5! = 5 * 4 * 3 * 2 * 1. You can find examples of that all over the place. For something that might actually show up in gaming, you'd probably want to look to anything that has to handle syntax according to some sort of defined grammar. That is, anything that looks like a compiler or an interpreter. Any development kit for a game engine is likely to include some amount of recursion for handling syntax trees created in whatever scripting language they use. Hell, Omniconvert (a tool for converting PS2 codes between different cheat devices) has a small amount of recursion in it to handle nested conditional codes. Most PS2 cheat devices embed counts in the conditional codes, but the AR MAX uses terminator lines instead, so conditional code types go through a recursive algorithm that keeps track of how many lines are in the original and converted codes, and what the counts should be or where the terminators should be inserted. It also helps with validity checking. That tool is open source, if you want to take a look at it.

    Comment


    • #17
      Originally posted by Pyriel View Post
      You're asking for an example of a recursive function in a game? I don't think I can really do that for you. Recursion is one of those things that's a godsend when you need it, but 99.9% of the time you don't. If you're going to find recursion in a game, it would be something of a unicorn hunt in the high-level code. My guess is that you'd be more likely to find it in lower-level routines for rendering and media playback, but if there's a consistent need for recursion even at that level, it's likely to be encapsulated in drivers or on the hardware.

      The main reason is that true recursion requires the function to call itself, and the recursive calls continue to whatever depth is required. Then the whole thing bubbles back up to the original call. This is time-consuming and can be relatively costly in terms of system resources, which isn't good for a game. They have some large number of things they have to do in each game tick/frame, and waiting a recursive chain to complete can easily eat up too many cycles. Games typically function as "state machines", and break tasks down into units of what's required each frame. So if there actually was a task that might ordinarily lend itself well to recursion, it would probably be broken up into enough states to cover the worst case scenario of the game, and some part of it would be handled in each tick.

      A decay function for a sound effect might be a good example of something a game could conceivably handle recursively, but you'd have to look at the audio hardware. Even in the PS 1 days, that was something you requested from the SPU. If the SPU in some way does it recursively through software, it doesn't affect the game engine so much because a purpose-built piece of hardware is handling it. I'm about 90% sure that's all handled on the metal, though.

      In general computing terms, the go-to example of recursion is computing a factorial, e.g., 5! = 5 * 4 * 3 * 2 * 1. You can find examples of that all over the place. For something that might actually show up in gaming, you'd probably want to look to anything that has to handle syntax according to some sort of defined grammar. That is, anything that looks like a compiler or an interpreter. Any development kit for a game engine is likely to include some amount of recursion for handling syntax trees created in whatever scripting language they use. Hell, Omniconvert (a tool for converting PS2 codes between different cheat devices) has a small amount of recursion in it to handle nested conditional codes. Most PS2 cheat devices embed counts in the conditional codes, but the AR MAX uses terminator lines instead, so conditional code types go through a recursive algorithm that keeps track of how many lines are in the original and converted codes, and what the counts should be or where the terminators should be inserted. It also helps with validity checking. That tool is open source, if you want to take a look at it.
      A thousand apologies please Pyriel. You talk to me like I'm a hacker and I'm just a beginner LOL. What I try to say with all of this is that I can not understand much about how to create a Rapid Fire code, and what you are telling me about steps I could take to be able to focus on finding or creating this specific code in games. I think also what you try to say is that it is dangerous to create these types of code? It's a shame ... I would have liked to understand how to locate myself to create these codes. It's not my pleasure to go asking for code. I think it's better to learn to do the things you try to look for or do, do not you think? I do not know if it is annoying for all of you to ask every time how to do each thing, in my case if I knew how to do all these things, I would take the trouble to create a page or something to instruct all people who like this . Even in the future, I would like to collaborate with this kind of thing in this community
      Last edited by David Dezio; 05-30-2017, 09:02:01 PM.

      Comment


      • #18
        Would you recommend Pyriel? To follow through with all this or leave it? Because, it does not look very easy. And not to disturb anyone ... I feel tense not being able to grasp this LOL. And please thousand puzzles Pyriel
        Last edited by David Dezio; 05-30-2017, 09:06:32 PM.

        Comment


        • #19
          Oh, you wanted an example of how to make a rapid fire code? There has to be a tutorial for that somewhere, or even just one for infinite ammo.

          Unfortunately, I don't own the game you're looking at. I'm not even sure I still have any shooters for the PS2. I might have SOCOM in the attic somewhere, but at the moment going up there, dragging down a hypothetical disc, and creating a lesson with it isn't something I have time for. Sorry.

          Comment


          • #20
            LOL! Socom... brings back old memories of when I played it, I thought I was one of those few who played it. And it's a shame... I have the infinite ammo code of the game. But hey, I do not intend to steal anyone's time here

            Comment

            Working...
            X