Left 4 Dead 2

Left 4 Dead 2

242 arvostelua
Infected can disarm survivors
   
Palkinto
Lisää suosikkeihin
Lisätty suosikkeihin
Poista suosikeista
Game Content: Scripts
Game Modes: Single Player, Co-op
Tiedostokoko
Julkaistu
6.747 KB
30.12.2024 klo 18.18
1 muutos ( näytä )

Tilaa ladataksesi
Infected can disarm survivors

Kuvaus
This cusomisable mod lets the infected knock a survivors weapon to the ground if they hit them.

The CFG file in "ems\infected_disarm\disarm.txt" lets you edit 3 variables. You can change how likely an infected is to disarm a survivor when the survivor has high health, low health, and how much health is needed to be considered 'low health'. Using this, you can make injured survivors more likely to drop their weapons.
43 kommenttia
ponds33 (woman ponds) 3.8. klo 11.38 
You should add a setting to allow only special infected or common infected to disarm you, Its cool to have a tank disarm me whereas its annoying to lose my gun in the middle of a horde with nothing but a pistol to kill them
Geebanger0  [tekijä] 10.7. klo 3.41 
Ellis doesn't get stumbled there, he just runs away
withextradip 10.7. klo 0.12 
You should make the survivors stumble when they drop a weapon, similar to the video
rgawsome231 9.7. klo 18.21 
@Geebanger0

Many thanks for the explanation, I hope you have a fantastic night and good fortune on future projects!
Geebanger0  [tekijä] 9.7. klo 0.02 
If you get an error, it means that at some point during this the script failed. So long as it still otherwise works though, it's fine. Almost every script I make produces errors in console constantly. I don't know how/can't be bothered to make them in such a way that they don't produce the errors. The scripts still work perfectly fine otherwise, and most people don't check the console at all so they won't even know.

So yeah, unless the script doesn't work, you don't have to worry about the errors.
Geebanger0  [tekijä] 8.7. klo 23.59 
The function basically means this

When a player takes damage:
- Check which player it was who took the damage
- Check what damage type that player took. Every damage type has a corresponding number
- If the damage type equals 128 (which it should if a common infected hit the player):
-- Continue with the rest of the script
rgawsome231 8.7. klo 20.34 
Hey I don't know if you still watch over this mod but on line 117 to 122 which is this:

function OnGameEvent_player_hurt(event)
{
local victim = GetPlayerFromUserID(event.userid);
local damagetype = event.type;
if(damagetype == 128)

I think this is what causes error problems on my computer, as in the console it show it as "type is not a valid" something of this sort. I was wondering if you can explain what this function does and maybe review it to see if it happens on your end too.

Thank you for your time! :-3
Corveck (Fusion) 20.6. klo 22.42 
@an apocalypse fae It's not like anyone's asking you to download this lol
an apocalypse fae 16.6. klo 13.54 
i'd like to keep my reserve ammo :/
kouga 29.5. klo 23.19 
is it possible to add a variable in the cfg to blacklist what weapons can be dropped?