Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 21

Thread: [Perl] [COD2] Nanny

  1. #11
    Private
    Join Date
    Jul 2016
    Posts
    38
    Thanks
    0
    Thanked 19 Times in 19 Posts
    root@73:~# cpan DBD::SQLite
    Reading '/root/.cpan/Metadata'
    Database was generated on Sat, 17 Jun 2017 00:29:02 GMT
    Running install for module 'DBD::SQLite'
    Running make for I/IS/ISHIGAKI/DBD-SQLite-1.54.tar.gz
    Checksum for /root/.cpan/sources/authors/id/I/IS/ISHIGAKI/DBD-SQLite-1.54.tar.gz ok

    CPAN.pm: Building I/IS/ISHIGAKI/DBD-SQLite-1.54.tar.gz

    Checking if your kit is complete...
    Looks good
    Using DBI 1.63 (for perl 5.018002 on x86_64-linux-gnu-thread-multi) installed in /usr/lib/perl5/auto/DBI/
    Writing Makefile for DBD::SQLite
    Writing MYMETA.yml and MYMETA.json
    ISHIGAKI/DBD-SQLite-1.54.tar.gz
    make -- NOT OK
    'YAML' not installed, will not store persistent state
    Running make test
    Can't test without successful make
    Running make install
    Make had returned bad status, install seems impossible
    root@73:~#

  2. The Following User Says Thank You to bulent For This Useful Post:

    kubislav23 (28th June 2017)

  3. #12
    Assadministrator kung foo man's Avatar
    Join Date
    Jun 2012
    Location
    trailerpark
    Posts
    2,014
    Thanks
    2,110
    Thanked 1,086 Times in 753 Posts
    Based on this https://stackoverflow.com/questions/...ling-xmlsimple

    You either need: apt-get install build-essential

    Or: cpan YAML
    timescale 0.01

  4. The Following User Says Thank You to kung foo man For This Useful Post:

    kubislav23 (18th June 2017)

  5. #13
    Private
    Join Date
    Jul 2016
    Posts
    38
    Thanks
    0
    Thanked 19 Times in 19 Posts

    not work

    Quote Originally Posted by kung foo man View Post
    Based on this https://stackoverflow.com/questions/...ling-xmlsimple

    You either need: apt-get install build-essential

    Or: cpan YAML

    PHP Code:
    root@73:~/cod2/Nanny# apt-get install build-essential
    Reading package lists... Done
    Building dependency tree
    Reading state information
    ... Done
    The following extra packages will be installed
    :
      
    dpkg-dev fakeroot libalgorithm-diff-perl libalgorithm-diff-xs-perl
      libalgorithm
    -merge-perl libdpkg-perl libfakeroot libfile-fcntllock-perl
    Suggested packages
    :
      
    debian-keyring
    The following 
    NEW packages will be installed
      build
    -essential dpkg-dev fakeroot libalgorithm-diff-perl
      libalgorithm
    -diff-xs-perl libalgorithm-merge-perl libdpkg-perl libfakeroot
      libfile
    -fcntllock-perl
    0 to upgrade
    9 to newly install0 to remove and 3 not to upgrade.
    Need to get 1,082 kB of archives.
    After this operation4,083 kB of additional disk space will be used.
    Do 
    you want to continue? [Y/ny
    Get
    :1 http://tr.archive.ubuntu.com/ubuntu/ trusty-updates/main libdpkg-perl all 1.17.5ubuntu5.7 [179 kB]
    Get:2 http://tr.archive.ubuntu.com/ubuntu/ trusty-updates/main dpkg-dev all 1.17.5ubuntu5.7 [726 kB]
    Get:3 http://tr.archive.ubuntu.com/ubuntu/ trusty/main build-essential amd64 11.6ubuntu6 [4,838 B]
    Get:4 http://tr.archive.ubuntu.com/ubuntu/ trusty/main libfakeroot amd64 1.20-3ubuntu2 [25.4 kB]
    Get:5 http://tr.archive.ubuntu.com/ubuntu/ trusty/main fakeroot amd64 1.20-3ubuntu2 [55.0 kB]
    Get:6 http://tr.archive.ubuntu.com/ubuntu/ trusty/main libalgorithm-diff-perl all 1.19.02-3 [50.0 kB]
    Get:7 http://tr.archive.ubuntu.com/ubuntu/ trusty/main libalgorithm-diff-xs-perl amd64 0.04-2build4 [12.6 kB]
    Get:8 http://tr.archive.ubuntu.com/ubuntu/ trusty/main libalgorithm-merge-perl all 0.08-2 [12.7 kB]
    Get:9 http://tr.archive.ubuntu.com/ubuntu/ trusty/main libfile-fcntllock-perl amd64 0.14-2build1 [15.9 kB]
    Fetched 1,082 kB in 0s (3,672 kB/s)
    Selecting previously unselected package libdpkg-perl.
    (
    Reading database ... 67072 files and directories currently installed.)
    Preparing to unpack .../libdpkg-perl_1.17.5ubuntu5.7_all.deb ...
    Unpacking libdpkg-perl (1.17.5ubuntu5.7) ...
    Selecting previously unselected package dpkg-dev.
    Preparing to unpack .../dpkg-dev_1.17.5ubuntu5.7_all.deb ...
    Unpacking dpkg-dev (1.17.5ubuntu5.7) ...
    Selecting previously unselected package build-essential.
    Preparing to unpack .../build-essential_11.6ubuntu6_amd64.deb ...
    Unpacking build-essential (11.6ubuntu6) ...
    Selecting previously unselected package libfakeroot:amd64.
    Preparing to unpack .../libfakeroot_1.20-3ubuntu2_amd64.deb ...
    Unpacking libfakeroot:amd64 (1.20-3ubuntu2) ...
    Selecting previously unselected package fakeroot.
    Preparing to unpack .../fakeroot_1.20-3ubuntu2_amd64.deb ...
    Unpacking fakeroot (1.20-3ubuntu2) ...
    Selecting previously unselected package libalgorithm-diff-perl.
    Preparing to unpack .../libalgorithm-diff-perl_1.19.02-3_all.deb ...
    Unpacking libalgorithm-diff-perl (1.19.02-3) ...
    Selecting previously unselected package libalgorithm-diff-xs-perl.
    Preparing to unpack .../libalgorithm-diff-xs-perl_0.04-2build4_amd64.deb ...
    Unpacking libalgorithm-diff-xs-perl (0.04-2build4) ...
    Selecting previously unselected package libalgorithm-merge-perl.
    Preparing to unpack .../libalgorithm-merge-perl_0.08-2_all.deb ...
    Unpacking libalgorithm-merge-perl (0.08-2) ...
    Selecting previously unselected package libfile-fcntllock-perl.
    Preparing to unpack .../libfile-fcntllock-perl_0.14-2build1_amd64.deb ...
    Unpacking libfile-fcntllock-perl (0.14-2build1) ...
    Processing triggers for man-db (2.6.7.1-1ubuntu1) ...
    Setting up libdpkg-perl (1.17.5ubuntu5.7) ...
    Setting up dpkg-dev (1.17.5ubuntu5.7) ...
    Setting up build-essential (11.6ubuntu6) ...
    Setting up libfakeroot:amd64 (1.20-3ubuntu2) ...
    Setting up fakeroot (1.20-3ubuntu2) ...
    update-alternativesusing /usr/bin/fakeroot-sysv to provide /usr/bin/fakeroot (fakerootin auto mode
    Setting up libalgorithm
    -diff-perl (1.19.02-3) ...
    Setting up libalgorithm-diff-xs-perl (0.04-2build4) ...
    Setting up libalgorithm-merge-perl (0.08-2) ...
    Setting up libfile-fcntllock-perl (0.14-2build1) ...
    root@73:~/cod2/Nanny# ./nanny.sh
    Can't locate DBD/SQLite.pm in @INC (you may need to install the DBD::SQLite module) (@INC contains: /etc/perl /usr/local/lib/perl/5.18.2 /usr/local/share/perl/5.18.2 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.18 /usr/share/perl/5.18 /usr/local/lib/site_perl .) at nanny.pl line 65.
    BEGIN failed--compilation aborted at nanny.pl line 65 (#1)
        (F) You said to do (or require, or use) a file that couldn'
    t be found.
        
    Perl looks for the file in all the locations mentioned in @INCunless
        the file name included the full path to the file
    .  Perhaps you need
        to set the PERL5LIB 
    or PERL5OPT environment variable to say where the
        extra library is
    , or maybe the script needs to add the library name
        to 
    @INC.  Or maybe you just misspelled the name of the file.  See
        
    "require" in perlfunc and lib.

    Uncaught exception from user code:
            
    Can't locate DBD/SQLite.pm in @INC (you may need to install the DBD::SQLite module) (@INC contains: /etc/perl /usr/local/lib/perl/5.18.2 /usr/local/share/perl/5.18.2 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.18 /usr/share/perl/5.18 /usr/local/lib/site_perl .) at nanny.pl line 65.
            BEGIN failed--compilation aborted at nanny.pl line 65.
    root@73:~/cod2/Nanny# 

  6. The Following User Says Thank You to bulent For This Useful Post:

    kubislav23 (28th June 2017)

  7. #14
    Assadministrator IzNoGoD's Avatar
    Join Date
    Aug 2012
    Posts
    1,725
    Thanks
    17
    Thanked 1,080 Times in 682 Posts
    I see you havent even tried everything and area already out of ideas.

    Good job on sending me a private message about 30 minutes after responding to a thread. I will now never help you again, because you obviously can't read.
    "Does not work" is an error report for a bug between keyboard and chair.

    All hail Artie Effem

  8. #15
    Private First Class YuriJurek's Avatar
    Join Date
    Jun 2013
    Posts
    219
    Thanks
    152
    Thanked 88 Times in 47 Posts
    LMAO, it says it all right there in what you have pasted...

  9. #16
    Private
    Join Date
    Jul 2016
    Posts
    38
    Thanks
    0
    Thanked 19 Times in 19 Posts
    Hi guys
    nanny bot banned !ban good work but one question.Example:I banned aimbot reconnect aimbot 10-15 second play bot banned I want 1 second aimbot banned nannybot

  10. The Following User Says Thank You to bulent For This Useful Post:

    kubislav23 (29th January 2018)

  11. #17
    Private
    Join Date
    Jul 2016
    Posts
    38
    Thanks
    0
    Thanked 19 Times in 19 Posts

    Thumbs up

    Quote Originally Posted by IzNoGoD View Post
    I see you havent even tried everything and area already out of ideas.

    Good job on sending me a private message about 30 minutes after responding to a thread. I will now never help you again, because you obviously can't read.

    Proud IzNoGod so bad lol...

  12. #18
    Private
    Join Date
    Jul 2016
    Posts
    38
    Thanks
    0
    Thanked 19 Times in 19 Posts
    Quote Originally Posted by voron00 View Post
    Well, im not forcing anyone to use or develop it, just sharing. I don't know b3, never seen, never used.
    Anyways, a little hack for libcod users to make Nanny use sendGameServerCommand (change 'console' to 'whatever')

    callbacksetup.gsc

    PHP Code:
    //    Callback Setup
    //    This script provides the hooks from code into script for the gametype callback functions.

    //=============================================================================
    // Code Callback functions

    /*================
    Called by code after the level's main script function has run.
    ================*/
    CodeCallback_StartGameType()
    {
        
    // If the gametype has not beed started, run the startup
        
    if(!isDefined(level.gametypestarted) || !level.gametypestarted)
        {
            
    //disableGlobalPlayerCollision(); // libcod: disable player collisions
            
    thread consoleName();
            
    thread sayw();
            [[
    level.callbackStartGameType]]();
            
    level.gametypestarted true// so we know that the gametype has been started up
        
    }
    }

    /*================
    Called when a player begins connecting to the server.
    Called again for every map change or tournement restart.

    Return undefined if the client should be allowed, otherwise return
    a string with the reason for denial.

    Otherwise, the client will be sent the current gamestate
    and will eventually get to ClientBegin.

    firstTime will be qtrue the very first time a client connects
    to the server machine, but qfalse on map changes and tournement
    restarts.
    ================*/
    CodeCallback_PlayerConnect()
    {
        
    self endon("disconnect");
        
    self thread kickFakeClients();
        
    self thread unknown();
        [[
    level.callbackPlayerConnect]]();
    }

    /*================
    Called when a player drops from the server.
    Will not be called between levels.
    self is the player that is disconnecting.
    ================*/
    CodeCallback_PlayerDisconnect()
    {
        
    self notify("disconnect");
        [[
    level.callbackPlayerDisconnect]]();
    }

    /*================
    Called when a player has taken damage.
    self is the player that took damage.
    ================*/
    CodeCallback_PlayerDamage(eInflictoreAttackeriDamageiDFlagssMeansOfDeathsWeaponvPointvDirsHitLoctimeOffset)
    {
        
    self endon("disconnect");
        [[
    level.callbackPlayerDamage]](eInflictoreAttackeriDamageiDFlagssMeansOfDeathsWeaponvPointvDirsHitLoctimeOffset);
    }

    /*================
    Called when a player has been killed.
    self is the player that was killed.
    ================*/
    CodeCallback_PlayerKilled(eInflictoreAttackeriDamagesMeansOfDeathsWeaponvDirsHitLoctimeOffsetdeathAnimDuration)
    {
        
    self endon("disconnect");
        [[
    level.callbackPlayerKilled]](eInflictoreAttackeriDamagesMeansOfDeathsWeaponvDirsHitLoctimeOffsetdeathAnimDuration);
    }

    //=============================================================================

    /*================
    Setup any misc callbacks stuff like defines and default callbacks
    ================*/
    SetupCallbacks()
    {
        
    SetDefaultCallbacks();
        
    // Set defined for damage flags used in the playerDamage callback
        
    level.iDFLAGS_RADIUS            1;
        
    level.iDFLAGS_NO_ARMOR            2;
        
    level.iDFLAGS_NO_KNOCKBACK        4;
        
    level.iDFLAGS_NO_TEAM_PROTECTION    8;
        
    level.iDFLAGS_NO_PROTECTION        16;
        
    level.iDFLAGS_PASSTHRU            32;
    }

    /*================
    Called from the gametype script to store off the default callback functions.
    This allows the callbacks to be overridden by level script, but not lost.
    ================*/
    SetDefaultCallbacks()
    {
        
    level.default_CallbackStartGameType level.callbackStartGameType;
        
    level.default_CallbackPlayerConnect level.callbackPlayerConnect;
        
    level.default_CallbackPlayerDisconnect level.callbackPlayerDisconnect;
        
    level.default_CallbackPlayerDamage level.callbackPlayerDamage;
        
    level.default_CallbackPlayerKilled level.callbackPlayerKilled;
    }

    /*================
    Called when a gametype is not supported.
    ================*/
    AbortLevel()
    {
        
    println("Aborting level - gametype is not supported");
        
    level.callbackStartGameType = ::callbackVoid;
        
    level.callbackPlayerConnect = ::callbackVoid;
        
    level.callbackPlayerDisconnect = ::callbackVoid;
        
    level.callbackPlayerDamage = ::callbackVoid;
        
    level.callbackPlayerKilled = ::callbackVoid;
        
    setcvar("g_gametype""dm");
        
    exitLevel(false);
    }

    /*================
    ================*/
    callbackVoid()
    {
    }

    consoleName()
    {
        for (;;)
        {
            if (
    getCvar("consoleName") != "")
            {
                
    level.consoleName getCvar("consoleName");
            }
            
    wait 0.05;
        }
    }

    sayw()
    {
        
    setcvar("sayw""");
        for (;;)
        {
            if (
    getCvar("sayw") != "")
            {
                
    message getCvar("sayw");
                
    sendGameServerCommand(-1"h \"" level.consoleName "^7: " message "\"");
                
    setcvar("sayw""");
            }
            
    wait 0.05;
        }

    Then, in KKrcon.pm, replace this line
    PHP Code:
    if ($command =~ /^say\s(.*)/) { $command "say " '"' "$1" '"'; } 
    with
    PHP Code:
    if ($command =~ /^say\s(.*)/) { $command "sayw " '"' "$1" '"'; } 
    And start server with +set consoleName "^6Nanny"
    PHP Code:
    ******* script compile error *******
    bad syntax: (file 'maps/mp/gametypes/_callbacksetup.gsc'line 151)
                
    sendGameServerCommand(-1"h "" + level.consoleName + "^7" + message + """);
                                              *
    ************************************
    Sys_ErrorError during initialization:
    script compile error
    (see console for details)

    > [
    PLUGIN UNLOADED]: 

  13. #19
    Assadministrator kung foo man's Avatar
    Join Date
    Jun 2012
    Location
    trailerpark
    Posts
    2,014
    Thanks
    2,110
    Thanked 1,086 Times in 753 Posts
    PHP Code:
    sendGameServerCommand(-1"h \"" level.consoleName "^7: " message "\""); 
    For some reason the forum seems to remove the slash from \ when copying the code back into the textarea :S

    Just make sure to have the two \ in your code

    I might disable the complete color shit and stupid formatting in vbb editor.
    timescale 0.01

  14. #20
    Private
    Join Date
    Jul 2016
    Posts
    38
    Thanks
    0
    Thanked 19 Times in 19 Posts
    Quote Originally Posted by kung foo man View Post
    PHP Code:
    sendGameServerCommand(-1"h \"" level.consoleName "^7: " message "\""); 
    For some reason the forum seems to remove the slash from \ when copying the code back into the textarea :S

    Just make sure to have the two \ in your code

    I might disable the complete color shit and stupid formatting in vbb editor.
    (Maybe wrong that test.sh "+set consoleName $Nanny"\)

    PHP Code:
     #!/bin/bash

    sv_maxclients="32"
    fs_game="console"
    fs_homepath="/root/cod2"
    cod="/root/cod2/cod2_lnxded_1_0a"
    com_hunkMegs="256"
    config="by.cfg"
    cracked="1"
    net_port="28929"


    args=\
    "+set fs_homepath \"$fs_homepath\" "\
    "+set sv_cracked $cracked "\
    "+set fs_game $fs_game "\
    "+set net_port $net_port "\
    "+set com_hunkMegs $com_hunkMegs "\
    "+set sv_maxclients $sv_maxclients "\
    "+set fs_basepath \"$fs_homepath\" "\
    "+set consoleName $Nanny"\
    "+exec $config"


    LD_PRELOAD="/root/cod2/libcod/bin/libcod2_1_0.so" $cod $args +set g_gametype tdm +map mp_toujane 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •