mirror of
https://github.com/Nereziel/cs2-WeaponPaints.git
synced 2026-03-13 17:31:50 +00:00
Compare commits
2 Commits
build-408
...
7c59b105da
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7c59b105da | ||
|
|
4bae11b3c0 |
@@ -14,6 +14,7 @@ Unfinished, unoptimized and not fully functional ugly demo weapon paints plugin
|
|||||||
- Data syncs on player connect
|
- Data syncs on player connect
|
||||||
- Added command **`!wp`** to refresh skins ***(with cooldown in seconds can be configured)***
|
- Added command **`!wp`** to refresh skins ***(with cooldown in seconds can be configured)***
|
||||||
- Added command **`!ws`** to show website
|
- Added command **`!ws`** to show website
|
||||||
|
- Added command **`!skins`** to show menu with skins
|
||||||
- Added command **`!knife`** to show menu with knives
|
- Added command **`!knife`** to show menu with knives
|
||||||
- Added command **`!gloves`** to show menu with gloves
|
- Added command **`!gloves`** to show menu with gloves
|
||||||
- Added command **`!agents`** to show menu with agents
|
- Added command **`!agents`** to show menu with agents
|
||||||
|
|||||||
@@ -332,27 +332,13 @@ namespace WeaponPaints
|
|||||||
if (!PlayerHasKnife(player) && hasKnife)
|
if (!PlayerHasKnife(player) && hasKnife)
|
||||||
{
|
{
|
||||||
var newKnife = new CBasePlayerWeapon(player.GiveNamedItem(CsItem.Knife));
|
var newKnife = new CBasePlayerWeapon(player.GiveNamedItem(CsItem.Knife));
|
||||||
|
newKnife.AddEntityIOEvent("Kill", newKnife, null, "", 0.01f);
|
||||||
var newWeapon = new CBasePlayerWeapon(player.GiveNamedItem(CsItem.USP));
|
var newWeapon = new CBasePlayerWeapon(player.GiveNamedItem(CsItem.USP));
|
||||||
player.GiveNamedItem(CsItem.Knife);
|
player.GiveNamedItem(CsItem.Knife);
|
||||||
player.ExecuteClientCommand("slot3");
|
player.ExecuteClientCommand("slot3");
|
||||||
|
newWeapon.AddEntityIOEvent("Kill", newWeapon, null, "", 0.01f);
|
||||||
Server.NextFrame(() =>
|
|
||||||
{
|
|
||||||
try
|
|
||||||
{
|
|
||||||
if (newKnife != null && newKnife.IsValid)
|
|
||||||
newKnife.AddEntityIOEvent("Kill", newKnife, null, "", 0.01f);
|
|
||||||
if (newWeapon != null && newWeapon.IsValid)
|
|
||||||
newWeapon.AddEntityIOEvent("Kill", newWeapon, null, "", 0.01f);
|
|
||||||
}
|
|
||||||
catch (Exception ex)
|
|
||||||
{
|
|
||||||
Logger.LogWarning("Error AddEntityIOEvent " + ex.Message);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
foreach (var entry in weaponsWithAmmo)
|
foreach (var entry in weaponsWithAmmo)
|
||||||
{
|
{
|
||||||
foreach (var ammo in entry.Value)
|
foreach (var ammo in entry.Value)
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="CounterStrikeSharp.API" Version="1.0.358" />
|
<PackageReference Include="CounterStrikeSharp.API" Version="1.0.342" />
|
||||||
<PackageReference Include="Dapper" Version="2.1.66" />
|
<PackageReference Include="Dapper" Version="2.1.66" />
|
||||||
<PackageReference Include="MySqlConnector" Version="2.4.0" />
|
<PackageReference Include="MySqlConnector" Version="2.4.0" />
|
||||||
<PackageReference Include="Newtonsoft.Json" Version="13.0.4" />
|
<PackageReference Include="Newtonsoft.Json" Version="13.0.4" />
|
||||||
@@ -18,11 +18,11 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<None Update="lang\**\*.*" CopyToOutputDirectory="PreserveNewest" />
|
<None Update="lang\**\*.*" CopyToOutputDirectory="PreserveNewest" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<None Update="gamedata\*.*" CopyToOutputDirectory="PreserveNewest" />
|
<None Update="gamedata\*.*" CopyToOutputDirectory="PreserveNewest" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="MenuManagerApi">
|
<Reference Include="MenuManagerApi">
|
||||||
<HintPath>3rd_party\MenuManagerApi.dll</HintPath>
|
<HintPath>3rd_party\MenuManagerApi.dll</HintPath>
|
||||||
|
|||||||
Reference in New Issue
Block a user