Thread: The begin

Results 1 to 3 of 3
  1. #1
    OverlordSec's Avatar
    Join Date
    Dec 2010
    Gender
    male
    Posts
    3
    Reputation
    10
    Thanks
    0

    Lightbulb The begin

    First post smell like shit. But I want to improve my knowledge. And Im here to suggest create a tutorial about the begin. No, I wont to take my hand and say : oh! little boy! Do u want icecream ? What flavor ? No !
    I want to learn and I ever search much.

    I found in forum the programmer requirements. Im studying Assembly and C, again. But if possible, elucidate few locks in my progress and certanily from many many peoples, like me.

    How to enable a DEV console ? I found http://www.mpgh.net/forum/356-call-d...r-console.html

    But, this code is for inject after compiled in C or to inject in console ?
    I try in console, but thinking... No make sense. After all, Is it injected ?

    First I search by how to uncompress (decompress) and compress the source.
    I found the offzip and packzip, FastFile Tool. I was able to extract the .dat files and I got to extract the code.

    1. Copy offzip.exe and packzip.exe to dir
    2. In this dir, I put code_pre_gfx_mp.ff file, from BO dir in steamapps.
    3. C:\pack>offzip -a -z -15 code_pre_gfx_mp.ff ./ 0

    Offset file unzipper 0.3.3
    by Luigi Auriemma
    e-mail: aluigi@autistici.org
    web: aluigi.org

    - open input file: code_pre_gfx_mp.ff
    - enter in directory: ./
    - zip data to check: 32 bytes
    - zip windowBits: -15
    - seek offset: 0x00000000 (0)

    +------------+-------------+-------------------------+
    | hex_offset | blocks_dots | zip_size --> unzip_size |
    +------------+-------------+-------------------------+
    0x0000000e ............... 29051 --> 123104


    - 1 valid zip blocks found

    I realized that the header was fucked ! Right !?????????

    4. Now I have 0000000e.dat in my dir. Use a HEX editor to open it.
    U see a code like this


    In this Step I could not extract nothing useful (For my brain)

    5. I swap for common_mp.ff. Same process
    offzip -a -z -15 common_mp.ff ./ 0

    Oh a secret here: The size of file is : 57.232.416 bytes but...
    .................................................. ... 57232389 --> 106724530

    57.232.389 different 57.232.416 bytes

    - 1 valid zip blocks found

    Why ?

    After that I isolate part of code.

    maps/mp/gametypes/_serversettings.gsc.F......xW[O0.k.&P"&F.U=L0i@{.Sd.KMY.;Nq. .. %;wr...).^Hf$.'8"...~<é.Zl*..L. .!.^.bo}~t9..#.%w.7.d'D@.Ig$q .NP_!>Jo.RW5T@C.yAE,.*..z$*..0.% t#0."4.CNezt>.p!lB..*yh#%!A";#r. .yc..ssj#'%"5'.UrS.u..$d4X;Rr .s?W!..wwD7.qWQ.4.IF.!.H.سeu .5%9jL.j`j. [,H)p.T.)B(O.t-.|..vx8"B=..0. ...4~D!U.63|r.>|tsA/ԿV%.@3D.ZR}..̫|`iv[vW.Z%_. ɡ._.!WBP:.P.viJ..O...()$b. L}h..Ы·-.}.ݲ.Z*...GHC.Zc@qؾ{jv"2i6’<Z ~Sqhq%.!i&y5Thٷ.HQ&.nGoѥ6}`/BZze'=bCd).i..?".%~Yvy^F8&.չtn' 1.&RO8<4|p.C3D.}D.-.*d9@...E.D..?J.+e>.96$.Ny1.]?r&j4[cF(/.S<mɱ.."H.BX1_z...9BkJO-.&(ޮ.Y..V..m׫._._&毪m&. .J.TVNns9A_qAJ.w*&Kc״.<I M$7K.^$c$7K}.Β.,iD;.0.( ...

    Create a new file in hexeditor and... Put him, save and extract again...
    File save as sscode.dat

    C:\pack>offzip -a -z -15 sscode.dat ./ 0

    Offset file unzipper 0.3.3
    by Luigi Auriemma
    e-mail: aluigi@autistici.org
    web: aluigi.org

    - open input file: sscode.dat
    - enter in directory: ./
    - zip data to check: 32 bytes
    - zip windowBits: -15
    - seek offset: 0x00000000 (0)

    +------------+-------------+-------------------------+
    | hex_offset | blocks_dots | zip_size --> unzip_size |
    +------------+-------------+-------------------------+
    0x00000003 .
    - zlib Z_DATA_ERROR, the data in the file is not in zip format
    or uses a different windowBits value (-z). Try to use -z 15

    0x0000002a .
    - zlib Z_DATA_ERROR, the data in the file is not in zip format
    or uses a different windowBits value (-z). Try to use -z 15

    0x00000030 . 999 --> 5446
    0x0000042b .
    - zlib Z_DATA_ERROR, the data in the file is not in zip format
    or uses a different windowBits value (-z). Try to use -z 15

    0x0000044a .
    - zlib Z_DATA_ERROR, the data in the file is not in zip format
    or uses a different windowBits value (-z). Try to use -z 15

    0x00000454 . 665 --> 2684


    - 2 valid zip blocks found

    Generated: 00000030.dat and 00000454.dat


    Open the .dat files in text editor and VOIL : the code


    init()
    {
    level.hostname = GetDvar( #"sv_hostname");
    if(level.hostname == "")
    level.hostname = "BlackOpsPrivate";
    setdvar("sv_hostname", level.hostname);
    setdvar("ui_hostname", level.hostname);
    makedvarserverinfo("ui_hostname", "BlackOpsPrivate");

    level.motd = GetDvar( #"scr_motd");
    if(level.motd == "")
    level.motd = "";
    setdvar("scr_motd", level.motd);
    setdvar("ui_motd", level.motd);
    makedvarserverinfo("ui_motd", "");

    level.allowvote = GetDvar( #"g_allowvote");
    if(level.allowvote == "")
    level.allowvote = "1";
    setdvar("g_allowvote", level.allowvote);
    setdvar("ui_allowvote", level.allowvote);
    makedvarserverinfo("ui_allowvote", "1");

    if( !level.console )
    {
    level.allow_teamchange = GetDvar( #"g_allow_teamchange");
    if(level.allow_teamchange == "")
    level.allow_teamchange = "1";
    setdvar("g_allow_teamchange", level.allow_teamchange);
    setdvar("ui_allow_teamchange", level.allow_teamchange);
    }
    else
    {
    level.allow_teamchange = "0";
    if( GetDvarInt( #"xblive_privatematch" ) || GetDvarInt( #"xblive_basictraining" ) || !GetDvarInt( #"onlinegame" ) )
    {
    level.allow_teamchange = "1";
    }
    setdvar("ui_allow_teamchange", level.allow_teamchange);
    }
    makeDvarServerInfo( "ui_allow_teamchange", GetDvar( #"ui_allow_teamchange" ) );


    ............


    And now !? Change and do what with this ....
    Last edited by OverlordSec; 12-09-2010 at 09:33 AM.

  2. #2
    deetwodomglolz1's Avatar
    Join Date
    Apr 2010
    Gender
    male
    Location
    On Earth. Nuffsaid.
    Posts
    75
    Reputation
    10
    Thanks
    10
    My Mood
    Yeehaw
    wut

  3. #3
    Heartview's Avatar
    Join Date
    May 2010
    Gender
    male
    Location
    KY Cygni
    Posts
    9,208
    Reputation
    717
    Thanks
    2,873
    Uhm, well for starters this is in the wrong section. Second, your english is choppy so its hard to follow what you are doing. So this needs to be moved to the coding section, as this is not really a tutorial. Especially considering anybody that comes through the tutorial section will have no idea what to do with this.
    Texture Mods


    Obedear, the sky is low