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

[CS:GO] Does Sourcemod have any way to tell what player models the map loads?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
BoosterGold
Member
Join Date: Nov 2016
Old 03-02-2017 , 23:06   [CS:GO] Does Sourcemod have any way to tell what player models the map loads?
Reply With Quote #1

Has anyone written an .inc or functionality that allows a script to check what player models the map has selected? Like, to tell if the Counterterrorists are the SWAT, GIGN, or GSG9?
BoosterGold is offline
rogeraabbccdd
Veteran Member
Join Date: Jun 2015
Location: de_dust2
Old 03-03-2017 , 00:50   Re: [CS:GO] Does Sourcemod have any way to tell what player models the map loads?
Reply With Quote #2

NomisCZ's -N- Arms Fix can check player models in map kv and gamemodes.txt, I think you can take a look in his code.
But there are some maps that have the map-kv build into the bsp that this plugin can't check.
__________________

Please keep in mind, nobody have responsibility to help you, especially who don't try to Google first.
I only read messages in Chinese and English.

GitHub | Discord:Kento#2118

Last edited by rogeraabbccdd; 03-03-2017 at 01:10.
rogeraabbccdd is offline
andi67
Veteran Member
Join Date: Mar 2007
Location: Somewhere near you!!!
Old 03-03-2017 , 01:52   Re: [CS:GO] Does Sourcemod have any way to tell what player models the map loads?
Reply With Quote #3

Some maps have the kv's build into the bsp , the only way to catch them from every map is something like this on player_spawn:



char sModel[128];
GetEntPropString(client, Prop_Data, "m_ModelName", sModel, sizeof(sModel)); // Get the complete Modelname.
PrintToChat(client, "Modelname is : %s", sModel);
__________________
Waiting for HL3,Day of Defeat3 ,but will it ever come? So I'm gonna play COD WW2.>>>>SM_SKINCHOOSER<<<<
>>You need Models for DODS/CSS/CSGO , than click here!!!<<

Last edited by andi67; 03-03-2017 at 06:56.
andi67 is offline
BoosterGold
Member
Join Date: Nov 2016
Old 03-04-2017 , 00:13   Re: [CS:GO] Does Sourcemod have any way to tell what player models the map loads?
Reply With Quote #4

Quote:
Originally Posted by andi67 View Post
Some maps have the kv's build into the bsp , the only way to catch them from every map is something like this on player_spawn:



char sModel[128];
GetEntPropString(client, Prop_Data, "m_ModelName", sModel, sizeof(sModel)); // Get the complete Modelname.
PrintToChat(client, "Modelname is : %s", sModel);
This works!

Since I just want my plugin to check the faction, though, it might be simpler to have it check what hand/arm models are loaded. Which Entity do I point the GetEntPropString to check that?
BoosterGold is offline
andi67
Veteran Member
Join Date: Mar 2007
Location: Somewhere near you!!!
Old 03-04-2017 , 05:53   Re: [CS:GO] Does Sourcemod have any way to tell what player models the map loads?
Reply With Quote #5

char sArmsModel[128];
GetEntPropString(client, Prop_Send, "m_szArmsModel", sArmsModel, sizeof(sArmsModel));
PrintToChat(client, "ArmModel is : %s", sArmsModel);
__________________
Waiting for HL3,Day of Defeat3 ,but will it ever come? So I'm gonna play COD WW2.>>>>SM_SKINCHOOSER<<<<
>>You need Models for DODS/CSS/CSGO , than click here!!!<<
andi67 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 19:27.


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