Post: GivePlayerWeapon for 1.10
04-10-2014, 01:19 PM #1
(adsbygoogle = window.adsbygoogle || []).push({});
    public static class Conversions
{
public static uint G_Client = 0xF44480;
public static byte[] ReverseBytes(byte[] input)
{
Array.Reverse(input);
return input;
}
}


That is for g_client. Next, add this:


    
public static void SV_GameSendServerCommand(int Client, string Command)
{
CallFunction(0x590EA0, new object[]
{
Client,
0,
Command
});
}

    
private void GiveWeapon(int client, int weapon, int ammo, int akimbo)
{
CallFunction(0x0029244C, (uint)(Conversions.g_client+ (client * 0x3700)), weapon, akimbo);
CallFunction(0x0246BE4, (uint)(Conversions.g_client+ (client * 0x3700)), weapon, 0, ammo, 1);
CallFunction(0x590EA0, client, 0, "a \"" + weapon + "\"");
}
//0x0029244C- G_GivePlayerWeapon Offset
//0x0246BE4- Add_Ammo Offset
//0x590EA0- SV Offset
//0x3700 - Index/Intervnal




Code: (button)

Originally posted by another user
GiveWeapon(0, (weapon id here), 999, 0);
(adsbygoogle = window.adsbygoogle || []).push({});
04-10-2014, 04:26 PM #2
br0wniiez
Yung Chico
Nice, but all people need to do is look at their old code and just update the offsets with the ones posted.

Basically coding everything for everybody lol
04-10-2014, 06:20 PM #3
Mango_Knife
In my man cave
Originally posted by D3skm View Post
    public static class Conversions
{
public static uint G_Client = 0xF44480;
public static byte[] ReverseBytes(byte[] input)
{
Array.Reverse(input);
return input;
}
}


That is for g_client. Next, add this:


    
public static void SV_GameSendServerCommand(int Client, string Command)
{
CallFunction(0x590EA0, new object[]
{
Client,
0,
Command
});
}

    
private void GiveWeapon(int client, int weapon, int ammo, int akimbo)
{
CallFunction(0x0029244C, (uint)(Conversions.g_client+ (client * 0x3700)), weapon, akimbo);
CallFunction(0x0246BE4, (uint)(Conversions.g_client+ (client * 0x3700)), weapon, 0, ammo, 1);
CallFunction(0x590EA0, client, 0, "a \"" + weapon + "\"");
}
//0x0029244C- G_GivePlayerWeapon Offset
//0x0246BE4- Add_Ammo Offset
//0x590EA0- SV Offset
//0x3700 - Index/Intervnal




Code: (button)



Already been posted man
You must login or register to view this content.

The following 2 users say thank you to Mango_Knife for this useful post:

iNDMx, M-alShammary
04-11-2014, 10:21 AM #4
Originally posted by Knife View Post
Already been posted man
You must login or register to view this content.


Sorry
04-11-2014, 10:41 AM #5
Mango_Knife
In my man cave
Originally posted by D3skm View Post
Sorry


Sure, just saying.

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo