Unofficial Lockjaw patches

Thread in 'Discussion' started by jujube, 16 Feb 2008.

  1. jujube

    jujube Unregistered

    to make your own patch, download the Lockjaw source code here and follow the instructions in the readme located in the "docs" folder.


    let's give tepples a break, huh? [​IMG] post your patch here and see if people like it. include the Lockjaw version number, and maybe an .exe for people who want to try your mod without downloading all of the software needed for compiling LJ.


    an .exe can be placed in your LJ folder of the same version number to replace your existing .exe. you might want to create a 2nd LJ folder just for this purpose so you can still play the original.
     
  2. jujube

    jujube Unregistered

    i made a modified wallkick table for SRS. it allows all sorts of twists found in SRS and ARS, and it's pretty well optimized for finesse with fast DAS in 20G.


    Code:
    static const WallKickTable jlstzSRSKicksL = {
     { WK( 0,-1),WK(-1,-1),WK( 1,-1),WK( 0, 0),WK( 0, 1) }, // R->U
     { WK( 0,-1),WK(-1,-1),WK( 1,-1),WK(-1, 0),WK( 1, 0) }, // D->R
     { WK( 0,-1),WK(-1,-1),WK( 1,-1),WK( 0, 0),WK( 0, 1) }, // L->D
     { WK( 0, 0),WK( 0, 0),WK( 0,-1),WK( 0, 1),WK( 1, 1) } // U->L
    };
    
    static const WallKickTable iSRSKicksL = {
     { WK( 0, 0),WK(-1, 0),WK( 2, 0),WK(-1,-2),WK( 2, 1) }, // R->U
     { WK( 0, 0),WK( 1, 0),WK(-2, 0),WK( 1,-1),WK(-2, 1) }, // D->R
     { WK( 0, 0),WK( 1, 0),WK(-2, 0),WK(-2,-1),WK( 1, 2) }, // L->D
     { WK( 0, 0),WK(-1, 0),WK( 2, 0),WK( 2,-1),WK(-1, 2) } // U->L
    };
    
    static const WallKickTable jlstzSRSKicksR = {
     { WK( 0,-1),WK( 1,-1),WK(-1,-1),WK( 0, 0),WK( 0, 1) }, // L->U
     { WK( 0, 0),WK( 0, 0),WK( 0,-1),WK( 0, 1),WK(-1, 1) }, // U->R
     { WK( 0,-1),WK( 1,-1),WK(-1,-1),WK( 0, 0),WK( 0, 1) }, // R->D
     { WK( 0,-1),WK( 1,-1),WK(-1,-1),WK( 1, 0),WK(-1, 0) } // D->L
    };
    
    static const WallKickTable iSRSKicksR = {
     { WK( 0, 0),WK( 1, 0),WK(-2, 0),WK( 1,-2),WK(-2, 1) }, // L->U
     { WK( 0, 0),WK( 1, 0),WK(-2, 0),WK(-2,-1),WK( 1, 2) }, // U->R
     { WK( 0, 0),WK(-1, 0),WK( 2, 0),WK( 2,-1),WK(-1, 2) }, // R->D
     { WK( 0, 0),WK(-1, 0),WK( 2, 0),WK(-1,-1),WK( 2, 1) } // D->L
    };
    here's the .exe for Lockjaw 0.43:

    http://www.sendspace.com/file/1pnmd4


    don't let the piece colors fool you...this is not SRS. but you still have to choose SRS in the options menu.


    edit: the I is acting like deep drop is on so i better change it.


    edit: fixed and updated. like it never happened.


    ahh, these work and triple twists don't. this has to be a step in the right direction.


    [​IMG]
     
  3. Altimor

    Altimor a.k.a. Ghett0

    Erm, I can't compile the source..
     
  4. jujube

    jujube Unregistered

    updated SRS mod. at this point it's easier to mention the well known twists that don't work:


    SRS spin triples

    Atari I-spin


    the SRS EZ-TSS cave T-spin works, but follow the Atari example above it.


    it should be easy to pick up for anyone who plays with SRS or Arika rotation.


    Code:
    static const WallKickTable jlstzSRSKicksL = {
     { WK( 0,-1),WK( 1,-1),WK(-1,-1),WK( 0, 0),WK( 0, 1) }, // R->U
     { WK( 0,-1),WK(-1,-1),WK( 1,-1),WK(-1, 0),WK( 1, 0) }, // D->R
     { WK( 0,-1),WK(-1,-1),WK( 1,-1),WK( 0, 0),WK( 1, 0) }, // L->D
     { WK( 0, 0),WK( 0, 0),WK( 0,-1),WK( 0, 1),WK( 1, 1) } // U->L
    };
    
    static const WallKickTable iSRSKicksL = {
     { WK( 0, 0),WK(-1, 0),WK( 2, 0),WK(-1,-2),WK( 2, 1) }, // R->U
     { WK( 0, 0),WK( 1, 0),WK(-2, 0),WK( 1,-1),WK(-2, 1) }, // D->R
     { WK( 0, 0),WK( 1, 0),WK(-2, 0),WK(-2,-1),WK( 1, 2) }, // L->D
     { WK( 0, 0),WK(-1, 0),WK( 2, 0),WK( 2,-1),WK(-1, 2) } // U->L
    };
    
    static const WallKickTable jlstzSRSKicksR = {
     { WK( 0,-1),WK(-1,-1),WK( 1,-1),WK( 0, 0),WK( 0, 1) }, // L->U
     { WK( 0, 0),WK( 0, 0),WK( 0,-1),WK( 0, 1),WK(-1, 1) }, // U->R
     { WK( 0,-1),WK( 1,-1),WK(-1,-1),WK( 0, 0),WK(-1, 0) }, // R->D
     { WK( 0,-1),WK( 1,-1),WK(-1,-1),WK( 1, 0),WK(-1, 0) } // D->L
    };
    
    static const WallKickTable iSRSKicksR = {
     { WK( 0, 0),WK( 1, 0),WK(-2, 0),WK( 1,-2),WK(-2, 1) }, // L->U
     { WK( 0, 0),WK( 1, 0),WK(-2, 0),WK(-2,-1),WK( 1, 2) }, // U->R
     { WK( 0, 0),WK(-1, 0),WK( 2, 0),WK( 2,-1),WK(-1, 2) }, // R->D
     { WK( 0, 0),WK(-1, 0),WK( 2, 0),WK(-1,-1),WK( 2, 1) } // D->L
    };
    .exe: http://www.sendspace.com/file/rfhi4w


    ghetto: make sure you follow the readme in the "docs" folder that came with the LJ source.
     
  5. jujube

    jujube Unregistered

    [​IMG]
    fixed the lines that didn't allow this before.

    Code:
    static const WallKickTable jlstzSRSKicksL = {
     { WK( 0,-1),WK(-1,-1),WK( 1,-1),WK(-1, 0),WK( 0, 0) }, // D->R
    };
    
    static const WallKickTable jlstzSRSKicksR = {
     { WK( 0,-1),WK( 1,-1),WK(-1,-1),WK( 1, 0),WK( 0, 0) } // D->L
    };
    i also changed the I kick tables to hopefully save rotations while keeping things predictable.
    Code:
    static const WallKickTable iSRSKicksL = {
     { WK(-1,-2),WK( 0, 0),WK(-1, 0),WK( 2, 0),WK( 2, 1) }, // R->U
     { WK(-2, 0),WK(-1, 0),WK( 0, 0),WK(-2, 1),WK( 0, 2) }, // D->R
     { WK(-1, 0),WK(-2, 0),WK( 0, 0),WK(-2,-1),WK( 0, 2) }, // L->D
     { WK( 0, 0),WK( 0, 0),WK(-2,-1),WK(-1,-1),WK(-1, 2) } // U->L
    };
    
    static const WallKickTable iSRSKicksR = {
     { WK( 1,-2),WK( 0, 0),WK( 1, 0),WK(-2, 0),WK(-2, 1) }, // L->U
     { WK( 0, 0),WK( 0, 0),WK( 2,-1),WK( 1,-1),WK( 1, 2) }, // U->R
     { WK( 1, 0),WK( 2, 0),WK( 0, 0),WK( 2,-1),WK( 0, 2) }, // R->D
     { WK( 2, 0),WK( 1, 0),WK( 0, 0),WK( 2, 1),WK( 0, 2) } // D->L
    };
    and tepples' I twist behavior is still intact.


    [​IMG]
    rotate CW-CW or CCW-CW


    [​IMG]
    rotate CCW-CCW or CW-CCW


    .exe for Lockjaw 0.43:

    http://www.sendspace.com/file/aoiyiw
     
  6. jujube

    jujube Unregistered

  7. jujube

    jujube Unregistered

    i made separate wallkick tables for I, JL, O, SZ, and T. S and Z can kick the direction of rotation for the first rotation if basic rotation fails, while J,L,T won't attempt that behavior at all. a slight change was made with the kick order of the I. and the O now shifts 1 column left when rotated left, 1 column right when rotated right.


    why not tap the O left or right? because when your DAS is 16ms there's no such thing as a tap.


    as of now there are no kicks for I2, I3, L3.


    now i have to find a way to add 180 rotation wallkick tables.


    all the twists from the last version still work, as far as i can tell.


    http://www.sendspace.com/file/3rm6py


    edit: brought back some T behavior that i forgot to put in the new table. also added some more kick tests for J and L.

    http://www.sendspace.com/file/iot67w
     
  8. Muf

    Muf

    What is the initial tetromino orientation? SRS or ARS? (upside down or right side up? [​IMG] )


    EDIT: Actually, I think it would be best described as ARS being head-first and SRS being butt-first [​IMG].
     
  9. tepples

    tepples Lockjaw developer

    The nomenclature used in the LJ source code would describe the initial JLT orientations as "point-up" (SRS and TOD M4) or "point-down" (Arika and everything else).
     
  10. jujube

    jujube Unregistered

    the little pointy parts are up initially.
     
  11. Muf

    Muf

    Ah, not interesting to me then. I've been interested in creating an ARS-style rotation system (head-first orientations, sonic drop, locking soft drop, etc), but with SRS wallkicks and infinity. Basically, something to cool off with casually without suffering from the ARS->SRS tetlag.
     
  12. jujube

    jujube Unregistered

    not much you can do about the tetlag from the initial orientation change. but this system does allow every ARS twist and a bunch more.


    if anyone sees a situation where a piece is immobile but you think it should move, try and let me know (pictures or a replay would help). there are some situations where pieces become immobile that are intentional though. the I is the only piece that can kick more than 1 square in any direction.
     
  13. the flipped LJT shouldn't be a huge problem in regards to tetlag. i always thought the kicks and the szi orientations were the main hurdle.
     
  14. tepples

    tepples Lockjaw developer

    Version 0.44 overhauls the format of a rotation system in wktables.c. Instead of having an array of values, one for each rotation system, and chasing pointers all over the place, we now have a single struct that describes a single rotation system, including all its kick tables. This should make it easier for you all to come up with source code patches, and it will make it easier for me to eventually make a loader that takes rotation system definitions from a text file.


    There is one known bug in LJ-ARS: it doesn't have the Ti wall kicks for I. Are these nearly as important as the Ti floor kicks, which are present?
     

  15. They are less important... But they're still useful. While I'll use floorkicks constantly in a given session, I might only use the I wallkicks about one game in 10.
     
  16. jujube

    jujube Unregistered

    nice work cleaning up wktables.c tepples. i've already replaced SRS with "JRS" and should have a patch ready soon. i'll also include a text file showing which files i changed and how i changed them, if anyone prefers that.


    while using these buttons:

    rotate left twice, rotate left, rotate right, up, left, tap left, tap right, right

    in 20G with 16ms/60Hz DAS with manual locking...


    Code:
    Cleared 40 lines at level 135
    Pressed 254 keys (2.44/piece)
    (single: 5; double: 0; triple: 1; home run: 8; T single: 0; T double: 0; T triple: 0)
    Left 16 blocks behind
     
  17. Real coders use diff -u.
     
  18. that's impressive jujube
     
  19. jujube

    jujube Unregistered

    things are finally working right with the settings i'm using. i added "tap left" and "tap right" keys to be used along with 16ms/60Hz left/right.


    there's now support for interrupting left/right when you hit a tap key, and you'll hear the 4x4 square sound when this happens. it allows a move like this to be performed by pressing "right" then "tap left" without releasing "right":


    Code:
    |  OO  | |    OO| |   OO |
    |  OO  | |    OO| |   OO |
     ----------  ----------  ----------
    things that will break this behavior:

    * setting gluing->square in options

    * using sideways speed < 60Hz


    things that might break this behavior:

    * using DAS > 16ms


    instead of fixing these issues i'll most likely add a mode with presets.


    download lj044jrs.exe:

    http://www.sendspace.com/file/ouk2k1

    make a duplicate lj 0.44 folder and unzip into that, overwriting.


    i'll make a .stuffidid and have it up sometime tonight.
     
  20. REAL real coders use Vi [​IMG]

    but i can suggest - if you people not already know it - http://www.codeblocks.org/ . it looks likt the perfect tool (didnt tested it yet, because i am kind of stuck with microsoft visual studio 2008 plus the fantastic http://www.visualassist.com )[/url]


    here some features:

    Highlights:

    Open Source! GPLv3, no hidden costs.

    Cross-platform. Runs on Linux, Mac, Windows (uses wxWidgets).

    Written in C++. No interpreted languages or proprietary libs needed.

    Extensible through plugins


    Compiler:

    Multiple compiler support:

    GCC (MingW / GNU GCC)

    MSVC++

    Digital Mars

    Borland C++ 5.5

    Open Watcom

    ...and more

    Very fast custom build system (no makefiles needed)

    Support for parallel builds (utilizing your CPU's extra cores)

    Multi-target projects

    Workspaces to combine multiple projects

    Inter-project dependencies inside workspace

    Imports MSVC projects and workspaces (NOTE: assembly code not supported yet)

    Imports Dev-C++ projects
     

Share This Page