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

[L4D2]Item tips


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
phoenix0001
Senior Member
Join Date: Apr 2010
Location: China
Old 02-14-2018 , 09:58   [L4D2]Item tips
Reply With Quote #1

All items, weapons, melee, etc., all can add a message prompts, players pick up an item there will be a prompt to tell the player the function of this item and the special usage.

For example:
grenade_launcher
you can continuously hit the maximum 9 bullets.
https://forums.alliedmods.net/showthread.php?p=1495171

pumpshotgun
Missile System Can launch missiles
https://forums.alliedmods.net/showthread.php?t=136019
__________________
I like this BBS sharing of spirit

I come from China, my English is poor
phoenix0001 is offline
cravenge
Veteran Member
Join Date: Nov 2015
Location: ♫ Harmony ♫
Old 02-14-2018 , 19:58   Re: [L4D2]Item tips
Reply With Quote #2

This idea is similar to what I am working on. I would like to call it [L4D2] Weapon Stats but it heavily relies on Left 4 Downtown 2 extension for accurate reports of each weapon's attributes. I'll post screenshots for the progress when I'm home.
__________________

"Juunen go no watashi e, ima wa shiawase de shou ka?"

Last edited by cravenge; 02-14-2018 at 19:59.
cravenge is offline
phoenix0001
Senior Member
Join Date: Apr 2010
Location: China
Old 02-15-2018 , 01:16   Re: [L4D2]Item tips
Reply With Quote #3

Wow...Waiting.....
__________________
I like this BBS sharing of spirit

I come from China, my English is poor
phoenix0001 is offline
cravenge
Veteran Member
Join Date: Nov 2015
Location: ♫ Harmony ♫
Old 02-16-2018 , 05:49   Re: [L4D2]Item tips
Reply With Quote #5

Sorry for the delay, but I am working overtime. Give me about... 6 hours or a day, maybe?

I posted from my phone.
__________________

"Juunen go no watashi e, ima wa shiawase de shou ka?"

Last edited by cravenge; 02-16-2018 at 05:50.
cravenge is offline
Crasher_3637
AlliedModders Donor
Join Date: May 2012
Old 02-16-2018 , 06:52   Re: [L4D2]Item tips
Reply With Quote #6

Quote:
Originally Posted by cravenge View Post
Sorry for the delay, but I am working overtime. Give me about... 6 hours or a day, maybe?

I posted from my phone.
Ayy no worries! Take your time.
__________________
Crasher_3637 is offline
timtam95
Junior Member
Join Date: Feb 2018
Old 02-17-2018 , 16:22   Re: [L4D2]Item tips
Reply With Quote #7

Place l4d2weaponmsg.cfg in left4dead2/cfg/sourcemod or the plugin will create it for you upon loading.
Edit l4d2weaponmsg.cfg and place your custom messages.
Example:
cv_weapon_grenade_launcher_msg "You picked up a grenade launcher"

Or leave blank to show no message.
Attached Files
File Type: sp Get Plugin or Get Source (l4d2weaponmsg.sp - 40 views - 2.7 KB)
File Type: smx l4d2weaponmsg.smx (5.1 KB, 9 views)
File Type: cfg l4d2weaponmsg.cfg (1.7 KB, 18 views)
timtam95 is offline
phoenix0001
Senior Member
Join Date: Apr 2010
Location: China
Old 02-19-2018 , 04:27   Re: [L4D2]Item tips
Reply With Quote #8

l4d2weaponmsg.cfg
Can not load Chinese.

Can you replace it with PrintHintText?
__________________
I like this BBS sharing of spirit

I come from China, my English is poor

Last edited by phoenix0001; 02-19-2018 at 07:15.
phoenix0001 is offline
cravenge
Veteran Member
Join Date: Nov 2015
Location: ♫ Harmony ♫
Old 02-19-2018 , 05:30   Re: [L4D2]Item tips
Reply With Quote #9

Quote:
Originally Posted by timtam95 View Post
[...]
Simple yet useful.

Also, for the time being, I'm trying to add "custom" key values for each weapon. This serves for any plugins that modifies those weapons.

For example:
PHP Code:
// ...
    
"weapon_grenade_launcher"
    
{
        
"max_clips" "5" /* Even if you leave this blank, the plugin will use the default game convar instead. */
        
"max_ammo" "10" /* Even if you leave this blank, the plugin will use the default game convar instead. */
        
"damage" "1000" /* Even if you leave this blank, the plugin will use the default game convar instead. */
        
"custom"
        
{
            
"multi-clip_grenade_launcher-l4d2" "1"
        
}
    }
// ... 
Under there, you must list all the plugins that modifies the Grenade Launcher in order to display this to the client.
PHP Code:
Weapon Stats: (Grenade Launchers)

Maximum Clip5
Maximum Ammunition
10
Damage
1000

Add
-ons:
You can have more clips with this weapon by reloading.
  (
Courtesy of [L4D2Multi-Clip Grenade Launcher plugin)

1. Back 
__________________

"Juunen go no watashi e, ima wa shiawase de shou ka?"

Last edited by cravenge; 02-19-2018 at 05:30.
cravenge is offline
phoenix0001
Senior Member
Join Date: Apr 2010
Location: China
Old 02-19-2018 , 05:30   Re: [L4D2]Item tips
Reply With Quote #10

How to prompt melee weapons?
crowbar
frying_pan
machete
cricket_bat
baseball_bat
tonfa
electric_guitar
fireaxe
katana
golfclub
__________________
I like this BBS sharing of spirit

I come from China, my English is poor
phoenix0001 is offline
Reply


Thread Tools
Display Modes

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:06.


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