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

[Cs:Go] Change and pracache player models


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Roccoxx
AlliedModders Donor
Join Date: Jan 2012
Location: Argentina
Old 09-21-2014 , 19:25   [Cs:Go] Change and pracache player models
Reply With Quote #1

hey how i can change and precache the player model, for example this: http://s-low.net/forum/viewtopic.php...de84d89e5657bb
__________________
Tutorials here (Spanish)

Like as another Pijudo said: "Tired and retired"
Roccoxx is offline
Send a message via MSN to Roccoxx
Mitchell
~lick~
Join Date: Mar 2010
Old 09-22-2014 , 19:59   Re: [Cs:Go] Change and pracache player models
Reply With Quote #2

This plugin can add files to the download table, and also precache the models on mapstart, also a good example to learn on.
You would want to do:
Code:
PrecacheModel(MODEL_PATH, true);
on MapStart()

Last edited by Mitchell; 09-22-2014 at 20:00.
Mitchell is offline
Roccoxx
AlliedModders Donor
Join Date: Jan 2012
Location: Argentina
Old 09-22-2014 , 20:39   Re: [Cs:Go] Change and pracache player models
Reply With Quote #3

Quote:
Originally Posted by Mitchell View Post
This plugin can add files to the download table, and also precache the models on mapstart, also a good example to learn on.
You would want to do:
Code:
PrecacheModel(MODEL_PATH, true);
on MapStart()
yes i have, and use this: SetEntityModel(client, "models/player/ctm_sas_goas.mdl");

but i have an error with the model, same to this picture: https://forums.alliedmods.net/showthread.php?t=245910

what files i need to precache, you have a stock for me?
__________________
Tutorials here (Spanish)

Like as another Pijudo said: "Tired and retired"

Last edited by Roccoxx; 09-22-2014 at 20:42.
Roccoxx is offline
Send a message via MSN to Roccoxx
Roccoxx
AlliedModders Donor
Join Date: Jan 2012
Location: Argentina
Old 09-23-2014 , 17:46   Re: [Cs:Go] Change and pracache player models
Reply With Quote #4

i have the same problem, i change de original directory of server files:
materials/models/player/b4p/bdroid/head.vmt
materials/models/player/b4p/bdroid/head.vtf
materials/models/player/b4p/bdroid/head_normal.vtf
materials/models/player/b4p/bdroid/torso.vmt
materials/models/player/b4p/bdroid/torso.vtf
materials/models/player/b4p/bdroid/torso_normal.vtf
models/player/b4p/b4p_bdroid/bdroid.dx90.vtx
models/player/b4p/b4p_bdroid/bdroid.mdl
models/player/b4p/b4p_bdroid/bdroid.phy
models/player/b4p/b4p_bdroid/bdroid.vvd

to:
PHP Code:
new const String:model_tt[] = "bdroid"

public OnMapStart(){
    
precachear_model(model_tt)
    
    
AddFileToDownloadsTable("materials/models/player/bdroid/head.vmt")
    
AddFileToDownloadsTable("materials/models/player/bdroid/head.vtf")
    
AddFileToDownloadsTable("materials/models/player/bdroid/head_normal.vtf")
    
AddFileToDownloadsTable("materials/models/player/bdroid/torso.vmt")
    
AddFileToDownloadsTable("materials/models/player/bdroid/torso.vtf")
    
AddFileToDownloadsTable("materials/models/player/bdroid/torso_normal.vtf")
}

set model:
new 
String:modelo[100]
FormatEx(modelosizeof(modelo)-1"models/player/tc/%s/%s.mdl"model_ttmodel_tt)
SetEntityModel(clientmodelo);

stock precachear_model(const String:model[]){
    new 
String:modelito[100]
    
    
FormatEx(modelitosizeof(modelito)-1"models/player/tc/%s/%s.mdl"modelmodel)
    if(
FileExists(modelito)){
        
PrecacheModel(modelitotrue)
        
AddFileToDownloadsTable(modelito)
    }
    
    
FormatEx(modelitosizeof(modelito)-1"models/player/tc/%s/%s.dx90.vtx"modelmodel)
    if(
FileExists(modelito)) AddFileToDownloadsTable(modelito)
    
    
FormatEx(modelitosizeof(modelito)-1"models/player/tc/%s/%s.phy"modelmodel)
    if(
FileExists(modelito)) AddFileToDownloadsTable(modelito)
    
    
FormatEx(modelitosizeof(modelito)-1"models/player/tc/%s/%s.vvd"modelmodel)
    if(
FileExists(modelito)) AddFileToDownloadsTable(modelito)

and i have skins error in players :S
__________________
Tutorials here (Spanish)

Like as another Pijudo said: "Tired and retired"

Last edited by Roccoxx; 09-23-2014 at 17:46.
Roccoxx is offline
Send a message via MSN to Roccoxx
andi67
Veteran Member
Join Date: Mar 2007
Location: Somewhere near you!!!
Old 09-24-2014 , 05:53   Re: [Cs:Go] Change and pracache player models
Reply With Quote #5

Precache the 'mdl-file' on map Start.


Changing the paths in your snippet let you get this error, paths are stored in the mdl so you must edit it with hexeditor or decompile , change the paths in the qc-file and recompile........
__________________
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


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


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