Raised This Month: $51 Target: $400
 12% 

Make RegisterHam plugins had a zbot support


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Somie1998
New Member
Join Date: Oct 2022
Old 10-10-2022 , 23:41   Make RegisterHam plugins had a zbot support
Reply With Quote #1

i had a 2 plugins i want to make them had a zbot support what should i choose. client_connect(id) & client_putinserver(id)

https://forums.alliedmods.net/showpo...07&postcount=4

https://forums.alliedmods.net/showpo...0&postcount=10
Attached Files
File Type: sma Get Plugin or Get Source (HeadShot_4x_connect.sma - 55 views - 1.2 KB)
File Type: sma Get Plugin or Get Source (HeadShot_4x_putinserver.sma - 55 views - 1.2 KB)
Somie1998 is offline
Celena Luna
Veteran Member
Join Date: Aug 2013
Location: Nagazora
Old 10-11-2022 , 03:27   Re: Make RegisterHam plugins had a zbot support
Reply With Quote #2

I think client_connect should be enough
Use RegisterHamFromEntity with that id of player that both joined

Not sure if you need to DisableHamForward when the bot left though
__________________
My plugin:

Last edited by Celena Luna; 10-11-2022 at 03:27.
Celena Luna is offline
Somie1998
New Member
Join Date: Oct 2022
Old 10-12-2022 , 01:50   Re: Make RegisterHam plugins had a zbot support
Reply With Quote #3

Quote:
Originally Posted by Celena Luna View Post
I think client_connect should be enough
Use RegisterHamFromEntity with that id of player that both joined

Not sure if you need to DisableHamForward when the bot left though
Okay and talk about "DisableHamForward" should do i needed of not ???

Last edited by Somie1998; 10-12-2022 at 01:52.
Somie1998 is offline
Celena Luna
Veteran Member
Join Date: Aug 2013
Location: Nagazora
Old 10-12-2022 , 03:21   Re: Make RegisterHam plugins had a zbot support
Reply With Quote #4

Quote:
Originally Posted by Somie1998 View Post
Okay and talk about "DisableHamForward" should do i needed of not ???
nah, I just check, you don't actually need to disable it

PHP Code:
    if (!is_user_zbot(id) || get_pcvar_num(bot_quota) <= 0
        return
    
    
// Reg Ham Zbot
    
RegisterHamFromEntity(Ham_Spawnid"HamF_Spawn_Player")
    
RegisterHamFromEntity(Ham_Spawnid"HamF_Spawn_Player_Post"1)
    
RegisterHamFromEntity(Ham_TraceAttackid"HamF_TraceAttack")
    
RegisterHamFromEntity(Ham_TakeDamageid"HamF_TakeDamage")
    
RegisterHamFromEntity(Ham_TakeDamageid"HamF_TakeDamage_Post"1)
    
RegisterHamFromEntity(Ham_Killedid"HamF_Killed")
    
RegisterHamFromEntity(Ham_Killedid"HamF_Killed_Post"1)
    
//if (is_user_alive(id)) fw_PlayerSpawn_Post(id) 
__________________
My plugin:

Last edited by Celena Luna; 10-12-2022 at 03:22.
Celena Luna 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 03:09.


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