Terraria +20 Trainer

Discussion in 'Computer Programming, Emulation, and Game Modding' started by Rydian, Jan 18, 2013.

Jan 18, 2013

Terraria +20 Trainer by Rydian at 4:59 PM (2,192 Views / 1 Likes) 7 replies

  1. Rydian
    OP

    Member Rydian Resident Furvert™

    Joined:
    Feb 4, 2010
    Messages:
    27,883
    Location:
    Cave Entrance, Watching Cyan Write Letters
    Country:
    United States
    [​IMG]
    (I made other modifications, but they were like, "infinite crafting if you have spare materials" which is obsoleted by the ability to clone stuff anyways, so the primary list is down to 20.)

    http://rydian.net/trainers/Terraria_1.1.zip
    1. Run Terraria.

    2. Run the trainer (it'll find Terrara.exe and attach automatically).

    3. Read the "about" text to note when to enable codes.

    4. Have fun.
    Also note that this is for the official Steam version of Terraria, if you're using a cracked/modded version, Idunno' if this will work. Also this is made for the latest .NET 4.5, so you'll want to have that installed. It's not a requirement of the trainer itself, but the version that's installed changes the assembly that the game code gets turned into when it runs, and this only scans for the versions made with the latest .NET.
     
    Devin likes this.
  2. Janthran

    Member Janthran Solarian

    Joined:
    Sep 17, 2011
    Messages:
    3,777
    Location:
    The Pacific Northwet
    Country:
    United States
    This looks like the kind of thing a server would detect.. No?
     
  3. Rydian
    OP

    Member Rydian Resident Furvert™

    Joined:
    Feb 4, 2010
    Messages:
    27,883
    Location:
    Cave Entrance, Watching Cyan Write Letters
    Country:
    United States
    Vanilla servers are stupid and totally trust the client.

    Modded servers, however, will detect almost everything, and I didn't take any steps to make it work anyways. Most public servers are modded, thankfully.
     
  4. Deltaechoe

    Member Deltaechoe The Dopefish

    Joined:
    May 3, 2012
    Messages:
    509
    Country:
    United States
    What no "no delay" hacks (remembers CE + TNT fondly)
     
  5. Rydian
    OP

    Member Rydian Resident Furvert™

    Joined:
    Feb 4, 2010
    Messages:
    27,883
    Location:
    Cave Entrance, Watching Cyan Write Letters
    Country:
    United States
    Like, no fuse time on explosives?

    Didn't think of that since that's suicide in normal play.
     
  6. Deltaechoe

    Member Deltaechoe The Dopefish

    Joined:
    May 3, 2012
    Messages:
    509
    Country:
    United States
    no no no, I mean no delay building with infinite tnt, what that will do is throw tnt as fast as the server can handle or in some cases faster and crash it but i tried not to do that
     
  7. Rydian
    OP

    Member Rydian Resident Furvert™

    Joined:
    Feb 4, 2010
    Messages:
    27,883
    Location:
    Cave Entrance, Watching Cyan Write Letters
    Country:
    United States
    Ohhhh. Yeah I don't see a use for it other than destruction, so meh.
     
  8. Rydian
    OP

    Member Rydian Resident Furvert™

    Joined:
    Feb 4, 2010
    Messages:
    27,883
    Location:
    Cave Entrance, Watching Cyan Write Letters
    Country:
    United States
    So a two-parter here because you got me curious.

    • Explosives go off immediately.

      0B53FAAC - C7 46 40 B4000000 - mov [esi+40],000000B4
      Sets the duration of the explosive (180 ticks/frames) for grenades. Seems to be the same command (and thus duration) for bombs too, though each has their own separate line of code.

      0B53FA91 - C7 46 40 2C010000 - mov [esi+40],0000012C
      Dynamite, however, is 300 ticks/frames. Probably intended to give the user a bit more time (5 seconds opposed to three) to get the hell out of there, as a piece of TNT can easily kill a player without endgame stuff.

      0B562568 - FF 48 40 - dec [eax+40]
      Subtracts one per tick/frame. Done for all explosive types.

      So I'll just modify each of the three direction sets to a single frame. If I changed the decrement command to just set the remaining duration to 0 that'd likely work for all three at once, but AFAIK I can't fit a command like that in three bytes since there's an offset to consider (if somebody knows how, please tell) and I want to avoid any code relocation.

    • No item delay. This one's in two variables/addresses.

      The first one determines how often you can actually attempt to throw, and the second determines how long it is until you can throw an explosive again. Locking just this first one to 0 allows attempted throws rapidly, but the item is still only thrown at the right time (your character will just appear to throw air otherwise).

      The second address determines how often the items can actually be thrown, but if this is just locked without locking the first one, then a single "throw" of the item will actually throw a bunch of them in a row, since your character is locked in the "throw" state for a second or two.

      So both of these need to be locked for proper rapid-fire... and it turns out that this is the same concept used in the rapid-fire-ranged code, and speaking of which I need to go edit that code to work better.

    Unfortunately I didn't actually save the trainer creation crap for what's in the first post, and I don't feel like remaking it right now... also these things are pretty much only useful in griefing, I don't see a use for actual building or testing (you can use map editors to cut out portions of land without the precision inherent with TNT and such) so I'm not doing a release with these (and I didn't bother editing the code for the second part since I don't want this in the trainer anyways).
     

Share This Page