Raised This Month: $ Target: $400
 0% 

FM_AddToFullPack player invisible (and SOLID) for certain player


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
joseph9
Junior Member
Join Date: Nov 2016
Location: Poland
Old 12-21-2021 , 05:19   FM_AddToFullPack player invisible (and SOLID) for certain player
Reply With Quote #1

Hello, I need some help with it (if it's even possible)

Lets say I have 16 players per team. I would like each pair (taken by index) to see themselfes.

PHP Code:
new teamOne[16], teamTwo[16]

public 
plugin_init() {
  
RegisterHam(Ham_Spawn"player""Ham_PlayerSpawn"1)
  
register_forward(FM_AddToFullPack"client_AddToFullPack_P"1)
}

public 
Ham_PlayerSpawn(id) {
  if(
is_user_alive(id)) {
    
set_user_rendering(idkRenderFxNone000kRenderTransAlpha0)
  }
}

public 
client_AddToFullPack_P(eseentidhostflagsplayerpSet) {
  if(
player && id != ent && is_user_alive(id)) {
    if(
teamOne[ent] && teamTwo[id]) {
      
set_es(esES_RenderModekRenderNormal)
      
set_es(esES_RenderAmt1.0)
    }
    return 
FMRES_IGNORED;
  }
  return 
FMRES_IGNORED;

Much thanks for any help because I'm confused about this function

@EDIT

Ok. I've made some changes to this code and added for loop inside (i think it's overkill for AddToFullPack, lol) and it's checking if teamOne is equal to id and teamTwo is equal to ent and vice-versa. If you have better ideas, please let me know!

Last edited by joseph9; 12-26-2021 at 14:25. Reason: I've made little progress..
joseph9 is offline
 



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 11:29.


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