mirror of
https://github.com/Nereziel/cs2-WeaponPaints.git
synced 2026-03-13 09:29:31 +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
|
||||
- Added command **`!wp`** to refresh skins ***(with cooldown in seconds can be configured)***
|
||||
- Added command **`!ws`** to show website
|
||||
- Added command **`!skins`** to show menu with skins
|
||||
- Added command **`!knife`** to show menu with knives
|
||||
- Added command **`!gloves`** to show menu with gloves
|
||||
- Added command **`!agents`** to show menu with agents
|
||||
|
||||
@@ -332,27 +332,13 @@ namespace WeaponPaints
|
||||
if (!PlayerHasKnife(player) && hasKnife)
|
||||
{
|
||||
var newKnife = new CBasePlayerWeapon(player.GiveNamedItem(CsItem.Knife));
|
||||
newKnife.AddEntityIOEvent("Kill", newKnife, null, "", 0.01f);
|
||||
var newWeapon = new CBasePlayerWeapon(player.GiveNamedItem(CsItem.USP));
|
||||
player.GiveNamedItem(CsItem.Knife);
|
||||
player.ExecuteClientCommand("slot3");
|
||||
|
||||
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);
|
||||
}
|
||||
});
|
||||
newWeapon.AddEntityIOEvent("Kill", newWeapon, null, "", 0.01f);
|
||||
}
|
||||
|
||||
|
||||
foreach (var entry in weaponsWithAmmo)
|
||||
{
|
||||
foreach (var ammo in entry.Value)
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
</PropertyGroup>
|
||||
|
||||
<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="MySqlConnector" Version="2.4.0" />
|
||||
<PackageReference Include="Newtonsoft.Json" Version="13.0.4" />
|
||||
@@ -18,11 +18,11 @@
|
||||
<ItemGroup>
|
||||
<None Update="lang\**\*.*" CopyToOutputDirectory="PreserveNewest" />
|
||||
</ItemGroup>
|
||||
|
||||
|
||||
<ItemGroup>
|
||||
<None Update="gamedata\*.*" CopyToOutputDirectory="PreserveNewest" />
|
||||
</ItemGroup>
|
||||
|
||||
|
||||
<ItemGroup>
|
||||
<Reference Include="MenuManagerApi">
|
||||
<HintPath>3rd_party\MenuManagerApi.dll</HintPath>
|
||||
|
||||
Reference in New Issue
Block a user