Skip to content
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Donate
Collapse

Plutonium

Vl.Sunnyundefined

Vl.Sunny

@Vl.Sunny
About
Posts
5
Topics
2
Shares
0
Groups
0
Followers
6
Following
5

Posts

Recent Best Controversial

  • [Guide] [Debian] T5 Server on Linux VPS/Dedicated Server
    Vl.Sunnyundefined Vl.Sunny

    t6-gsc-utils.dll isnt being loaded from my t6/plugins folder when running the server resulting in one of my scripts not working properly. How/where are .dll file plugins loaded?

    BO1 Server Hosting Support

  • Server fog command
    Vl.Sunnyundefined Vl.Sunny

    Couldn't find a way for players to toggle fog without enabling cheats so I made this script.

    Note: This script requires you to install RESXT's main chat_commands script in order to work properly.

    Fog can be toggled on or off by typing your command prefix (default is !) followed by setfog 1 or setfog 0
    e.g. (!setfog 1) in chat

    9b8f3982-f53b-48bf-9401-fb33db221a3c-image.png

    8739b325-ae66-44fa-8e03-0207e74575fe-image.png

    71c7be19-5e17-425a-ad5c-65879e87a4ea-image.png

    Script should be copy and pasted into your plutonium server folder at
    c:\storage\t6\scripts\zm

    #include maps\mp\_utility;
    #include common_scripts\utility;
    #include maps\mp\gametypes_zm\_hud_util;
    #include maps\mp\gametypes_zm\_hud_message;
    #include scripts\chat_commands;
    
    Init()
    {
        CreateCommand(level.chat_commands["ports"], "setfog", "function", ::setFogCommand, 1);
    }
    
    setFogCommand(args)
    {
        player = self;
    
        if (args.size != 1)
        {
            player TellPlayer(array("^3Usage: .setfog <0|1>"), 1);
            return;
        }
    
        fogState = int(args[0]);
    
        if (fogState == 0)
        {
            player setClientDvar("r_fog", 0);
            player TellPlayer(array("^1Fog Disabled"), 1);
        }
        else if (fogState == 1)
        {
            player setClientDvar("r_fog", 1);
            player TellPlayer(array("^2Fog Enabled"), 1);
        }
        else
        {
            player TellPlayer(array("^3Invalid fog state. Use 0 or 1."), 1);
        }
    }
    
    BO2 Modding Releases & Resources

  • Wall buy fills weapon clip to max
    Vl.Sunnyundefined Vl.Sunny

    Couldn't find any working scripts so I made a server script that fills the clip to max when buying ammo from a wall buy.

    Script should be copy and pasted into your plutonium server folder at
    c:\storage\t6\scripts\zm

    Also I'm new to all of this stuff so let me know if there are any bugs or things that can be fixed, thanks!

    #include common_scripts\utility;
    #include maps\mp\_utility;
    #include maps\mp\zombies\_zm_utility;
    #include maps\mp\zombies\_zm_weapons;
    main()
    {
    	replaceFunc(maps\mp\zombies\_zm_weapons::ammo_give,::new_ammo_give);
    }
    new_ammo_give( weapon ) //checked changed to match cerberus output
    {
        give_ammo = 0;
        fill_clip = 0; // Add a flag to control clip filling
        if ( !is_offhand_weapon( weapon ) )
        {
            weapon = get_weapon_with_attachments( weapon );
            if ( isDefined( weapon ) )
            {
                stockmax = 0;
                stockmax = weaponstartammo( weapon );
                clipmax = weaponclipsize( weapon ); // Get the maximum clip size
                clipcount = self getweaponammoclip( weapon );
                currstock = self getammocount( weapon );
                stockleft = currstock - clipcount;
                if ( stockleft < stockmax )
                {
                    give_ammo = 1;
                }
                // Always fill the clip when buying ammo for a primary weapon
                if ( clipcount < clipmax )
                {
                    fill_clip = 1;
                }
            }
        }
        else if ( self has_weapon_or_upgrade( weapon ) )
        {
            if ( self getammocount( weapon ) < weaponmaxammo( weapon ) )
            {
                give_ammo = 1;
                // For offhand weapons, we might not want to automatically "refill" in the same way
                // Consider if you want to add a specific clip mechanic for offhands.
            }
        }
        if ( give_ammo || fill_clip ) // Give ammo OR fill the clip
        {
            self play_sound_on_ent( "purchase" );
            if ( give_ammo )
            {
                self givemaxammo( weapon );
                alt_weap = weaponaltweaponname( weapon );
                if ( alt_weap != "none" )
                {
                    self givemaxammo( alt_weap );
                }
            }
            if ( fill_clip )
            {
                self setweaponammoclip( weapon, clipmax ); // Fill the clip to max
            }
            return 1;
        }
        return 0;
    }
    
    BO2 Modding Releases & Resources

  • Sign ups for Server-Owners channel - Discord
    Vl.Sunnyundefined Vl.Sunny

    Discord username: vlsunny
    a184a3fd-4f99-49ed-8ad7-cacd7ebfe5a1-image.png

    General Discussion

  • [Release] [ZM] High Round Tracker
    Vl.Sunnyundefined Vl.Sunny

    got it working but do you know a way to make a chat command to display the records?

    BO2 Modding Releases & Resources
  • 1 / 1
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Donate