Raised This Month: $32 Target: $400
 8% 

[L4D/L4D2] Grenade Throwing Bots


Post New Thread Reply   
 
Thread Tools Display Modes
deedeedee
Junior Member
Join Date: Oct 2020
Old 10-24-2020 , 10:13   Re: [L4D/L4D2] Grenade Throwing Bots
Reply With Quote #161

Quote:
Originally Posted by MasterMe View Post
Can you verify you have the following? Perhaps try reinstalling or updating these.

After this, running "sm_l4dhooks_detours" in the server console has to produce output, and it should include something for the grenade throwing plugin.
I ended up replacing my sourcemod folders, even though I had the exact version that was released and they seem to be working again. The only issue is how my bots tend to not do much with hordes still with car alarms. They do throw molotovs at hordes/events, but rarely a pipebomb.
deedeedee is offline
deedeedee
Junior Member
Join Date: Oct 2020
Old 10-24-2020 , 10:59   Re: [L4D/L4D2] Grenade Throwing Bots
Reply With Quote #162

Another question is that is it possible to get bots to throw pipebombs at Tanks? I've made a command so pipebombs explode really early, so I was hoping there's a way to do it.
deedeedee is offline
MasterMe
Member
Join Date: Mar 2010
Location: Netherlands
Old 10-24-2020 , 16:27   Re: [L4D/L4D2] Grenade Throwing Bots
Reply With Quote #163

Quote:
Originally Posted by Crasher_3637 View Post
You are correct. Making them throw two seconds earlier helped to compensate for the bots' "dumbness" because they would often just stand there with a grenade in their hand while they get swarmed. By the time they would finally throw one, another bot would throw one as well. Plus, most of their health would already be gone on higher difficulties.
This makes a lot of sense, and indeed better to throw early 9 times than to throw late and die 1 time, at least for higher difficulties. 3 seconds sound like the better thing to do then.

Quote:
Originally Posted by deedeedee View Post
I ended up replacing my sourcemod folders, even though I had the exact version that was released and they seem to be working again. The only issue is how my bots tend to not do much with hordes still with car alarms. They do throw molotovs at hordes/events, but rarely a pipebomb.
It could be that in the game (or left 4 dhooks?) the regular horde spawn and car alarm event are different, meaning the plugin doesn't currently know about car alarm? I don't have enough experience for this, but it would explain if they never react to car alarm.

For hordes/events it just selects some bot, and if this bot has a grenade that is "allowed", it will use it. So if the first bot it checks happen to have a molotov it will use a molotov. There is no preference or anything smart going on.

Quote:
Originally Posted by deedeedee View Post
Another question is that is it possible to get bots to throw pipebombs at Tanks? I've made a command so pipebombs explode really early, so I was hoping there's a way to do it.
Yeah, you can do this. For my version of the plugin this can be found on line 238:

Code:
ChangeToGrenade(chosenThrower, true, _, true);
The last three options are molotov, pipe and bile. This controls what grenades may be used for the tank, assuming this grenade type is allowed (cvar) and tank targeting is enabled (cvar). If you change this to:

Code:
ChangeToGrenade(chosenThrower, true, true, true);
Bots will also throw pipes at tanks.
__________________
MasterMe is offline
Mi.Cura
Veteran Member
Join Date: Dec 2016
Location: Brazil
Old 10-24-2020 , 18:27   Re: [L4D/L4D2] Grenade Throwing Bots
Reply With Quote #164

Quote:
Originally Posted by MasterMe View Post
[L4D(2)] Grenade Throwing Bots (1.9) [2020-10-23]

I have updated the version posted by Crasher_3637 above and made the following changes:
  • Support L4D1 and L4D2 in a single plugin.
  • Add cvar to specify if bots are allowed to use bile (default YES).
  • Add cvar to specify if bots are allowed to use molotov (default NO).
  • Add cvar to specify if bots are allowed to use pipe (default YES).
  • Add cvar to specify if bots can target (throw grenades at) tank (default NO).

The reason molotov and tank targeting are disabled by default is because these are too dangerous and unreliable on harder difficulty, such as advanced or expert. It happened to me that a bot really messed up a molotov throw in realism expert, killing the entire team. If you play on easier difficulties, or versus, enabling molotov and tank targeting should be ok.

New cvars, see cfg/sourcemod/l4d_grenade_throwing_bots.cfg (for L4D1, the l4d_gtb_allowbile will not be created, plugin autocreates cfg file on first load.)

Code:
// Allow bots to use bile. 0=Off, 1=On.
// -
// Default: "1"
l4d_gtb_allowbile "1"

// Allow bots to use molotov. 0=Off, 1=On.
// -
// Default: "0"
l4d_gtb_allowmolotov "0"

// Allow bots to use pipe. 0=Off, 1=On.
// -
// Default: "1"
l4d_gtb_allowpipe "1"

// Target tank with bile (L4D2) or molotov, if grenade type is allowed. 0=Off, 1=On.
// -
// Default: "0"
l4d_gtb_targettank "0"
Requires Left 4 Dhooks, just like previous versions.

Tested in L4D2 without any issues, can someone test on L4D1 and say if it works properly?

The plugin has been renamed, make sure to delete the old one!

Your version works well for me, without errors.
Thank you.
__________________
Mi.Cura | Modded Servers | L4D2
https://steamcommunity.com/groups/micuramodzombie
Mi.Cura is offline
deedeedee
Junior Member
Join Date: Oct 2020
Old 10-25-2020 , 07:09   Re: [L4D/L4D2] Grenade Throwing Bots
Reply With Quote #165

Quote:
Originally Posted by MasterMe View Post
This makes a lot of sense, and indeed better to throw early 9 times than to throw late and die 1 time, at least for higher difficulties. 3 seconds sound like the better thing to do then.



It could be that in the game (or left 4 dhooks?) the regular horde spawn and car alarm event are different, meaning the plugin doesn't currently know about car alarm? I don't have enough experience for this, but it would explain if they never react to car alarm.

For hordes/events it just selects some bot, and if this bot has a grenade that is "allowed", it will use it. So if the first bot it checks happen to have a molotov it will use a molotov. There is no preference or anything smart going on.



Yeah, you can do this. For my version of the plugin this can be found on line 238:

Code:
ChangeToGrenade(chosenThrower, true, _, true);
The last three options are molotov, pipe and bile. This controls what grenades may be used for the tank, assuming this grenade type is allowed (cvar) and tank targeting is enabled (cvar). If you change this to:

Code:
ChangeToGrenade(chosenThrower, true, true, true);
Bots will also throw pipes at tanks.
Yep, they throw pipebombs at tanks now. Thank you!

Also, I can see what you mean with the horde/car alarms. I should've said it better though. They mainly throw molotovs during events, like at the lift in No Mercy or car alarms, same with hordes. They seem to rarely use pipebombs, however. I don't mind it, though.

Last edited by deedeedee; 10-25-2020 at 07:09.
deedeedee is offline
MasterMe
Member
Join Date: Mar 2010
Location: Netherlands
Old 10-25-2020 , 23:06   Re: [L4D/L4D2] Grenade Throwing Bots
Reply With Quote #166

Quote:
Originally Posted by MasterMe View Post
This makes a lot of sense, and indeed better to throw early 9 times than to throw late and die 1 time, at least for higher difficulties. 3 seconds sound like the better thing to do then.
Just a little fyi: today a horde spawned close and the bot threw the pipebomb at the perfect moment, 2 seconds later would have been too late for sure! So timer 3 seconds is a better setting imo.
__________________

Last edited by MasterMe; 10-25-2020 at 23:07. Reason: English
MasterMe is offline
cravenge
Veteran Member
Join Date: Nov 2015
Location: Chocolate Factory
Old 10-26-2020 , 08:37   Re: [L4D/L4D2] Grenade Throwing Bots
Reply With Quote #167

In the future update, these are what to be expected:

- Better checks when the plugin should perform its duty (i.e Not allow bots to throw anything if a human player decides to use their own grenades).
- Proper method of horde detection.
- More accurate aim for bots throwing grenades at Tanks.
cravenge is offline
deedeedee
Junior Member
Join Date: Oct 2020
Old 10-26-2020 , 22:39   Re: [L4D/L4D2] Grenade Throwing Bots
Reply With Quote #168

Quote:
Originally Posted by cravenge View Post
In the future update, these are what to be expected:

- Better checks when the plugin should perform its duty (i.e Not allow bots to throw anything if a human player decides to use their own grenades).
- Proper method of horde detection.
- More accurate aim for bots throwing grenades at Tanks.
Nice to know! Small questions, though.
What do you mean by ''proper method of horde detection'' exactly? Does this mean they'll be able to understand when to throw molotovs and pipebombs in hordes and events?
Will we also be able to change it so we can have bots throw pipebombs and molotovs at the Tanks? I'm asking this due to having a small pipebomb timer so it explodes much quicker and it's more affected. I have this on so bots with pipebombs can stun the Tank.
deedeedee is offline
woohood
New Member
Join Date: Nov 2020
Old 07-03-2021 , 20:19   Re: [L4D/L4D2] Grenade Throwing Bots
Reply With Quote #169

Was curious and wanted to check this plugin out!
Will it be possible that we'd be seeing a new update of sorts sometime this year for L4D1?
woohood is offline
Mi.Cura
Veteran Member
Join Date: Dec 2016
Location: Brazil
Old 10-22-2021 , 14:19   Re: [L4D/L4D2] Grenade Throwing Bots
Reply With Quote #170

I'm getting this message. ( SourceMod v1.11.0.6775 )

L 10/21/2021 - 15:11:02: [SM] Exception reported: Property "m_vecOrigin" not found (entity 117/predicted_viewmodel)
L 10/21/2021 - 15:11:02: [SM] Blaming: l4d_grenade_throwing_bots.smx
L 10/21/2021 - 15:11:02: [SM] Call stack trace:
L 10/21/2021 - 15:11:02: [SM] [0] GetEntPropVector
L 10/21/2021 - 15:11:02: [SM] [1] Line 387, l4d_grenade_throwing_bots.sp::L4D2_OnFindScav engeItem
L 10/21/2021 - 15:11:02: [SM] [3] Call_Finish
L 10/21/2021 - 15:11:02: [SM] [4] Line 8945, C:\Servers\L4D2\left4dead2\addons\sourcemod\s cripting\left4dhooks.sp::OnFindScavengeItem
Attached Files
File Type: sp Get Plugin or Get Source (l4d_grenade_throwing_bots.sp - 172 views - 16.8 KB)
__________________
Mi.Cura | Modded Servers | L4D2
https://steamcommunity.com/groups/micuramodzombie
Mi.Cura is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 15:18.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode