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

[Guía] Setear modelos con Player Models API


  
 
 
Thread Tools Display Modes
baneado
Veteran Member
Join Date: Dec 2012
Location: amxmodx-es.com
Old 01-22-2013 , 04:54   Re: [Guía] Setear modelos con Player Models API
#11

Quote:
Originally Posted by DJHD! View Post
No, por qué cada uno le setea una información diferente.

Si quieres ahorrarte lineas y llamados loopealo y hazlo dentro del zp para no usar arrays.
Bler tiene razon en el primero, lo de frozen va fuera
baneado is offline
crypteR
Senior Member
Join Date: Jan 2012
Old 02-26-2013 , 09:31   Re: [Guía] Setear modelos con Player Models API
#12

Pusiste esto:
Code:
    // Custom models stuff     static Rand                   // Set the right model, after checking that we don't already have it     if (get_pcvar_num(cvar_adminmodelshuman) && (get_user_flags(id) & g_access_flag[ACCESS_ADMIN_MODELS]))     {         iRand = random_num(0, ArraySize(model_admin_human) - 1)         ArrayGetString(model_admin_human, iRand, g_playermodel[id], charsmax(g_playermodel[]))         cs_set_player_model(id, g_playermodel[id])     }     else     {         iRand = random_num(0, ArraySize(model_human) - 1)         ArrayGetString(model_human, iRand, g_playermodel[id], charsmax(g_playermodel[]))         cs_set_player_model(id, g_playermodel[id])     }               // Remove glow     fm_set_rendering(id)  <font color="#000000"><font color="#007700"> </font></font>


El static se llama Rand , pero lo que modificas se llama iRand , Error al escribir? o es así ?
__________________
crypteR is offline
baneado
Veteran Member
Join Date: Dec 2012
Location: amxmodx-es.com
Old 02-26-2013 , 13:37   Re: [Guía] Setear modelos con Player Models API
#13

Quote:
Originally Posted by crypteR View Post
Pusiste esto:
Code:
    // Custom models stuff     static Rand                   // Set the right model, after checking that we don't already have it     if (get_pcvar_num(cvar_adminmodelshuman) && (get_user_flags(id) & g_access_flag[ACCESS_ADMIN_MODELS]))     {         iRand = random_num(0, ArraySize(model_admin_human) - 1)         ArrayGetString(model_admin_human, iRand, g_playermodel[id], charsmax(g_playermodel[]))         cs_set_player_model(id, g_playermodel[id])     }     else     {         iRand = random_num(0, ArraySize(model_human) - 1)         ArrayGetString(model_human, iRand, g_playermodel[id], charsmax(g_playermodel[]))         cs_set_player_model(id, g_playermodel[id])     }               // Remove glow     fm_set_rendering(id)  <font color="#000000"><font color="#007700"> </font></font>


El static se llama Rand , pero lo que modificas se llama iRand , Error al escribir? o es así ?
error al escribir xd
baneado is offline
xPecie
Senior Member
Join Date: Dec 2012
Location: amxmodx-es.com
Old 07-16-2013 , 10:18   Re: [Guía] Setear modelos con Player Models API
#14

Error: Undefined symbol "iRand" on line 2124
Error: Undefined symbol "iRand" on line 2125
Warning: Expression has no effect on line 2125
Warning: Expression has no effect on line 2125
Error: Expected token: ";", but found ")" on line 2125
Error: Invalid expression, assumed zero on line 2125
Error: Too many error messages on one line on line 2125

2124: iRand = random_num(0, ArraySize(model_admin_human) - 1)
2125: ArrayGetString(model_admin_human, iRand, g_playermodel[id], charsmax(g_playermodel[]))

Codigo:

PHP Code:
    if (get_pcvar_num(cvar_adminmodelshuman) && (get_user_flags(id) & g_access_flag[ACCESS_ADMIN_MODELS]))
    {
        
iRand random_num(0ArraySize(model_admin_human) - 1)
        
ArrayGetString(model_admin_humaniRandg_playermodel[id], charsmax(g_playermodel[]))
        
cs_set_player_model(idg_playermodel[id])
    } 
Siguiendo el tutorial 100%

Uso zombie plague advance 1.6.1 por que tiene varios modos ya que solo no pude agregarle mas (no se hacerlo) soy novato y como comprenderan los errores si los escribiese todos no tendría tiempo de acabar nunca.

Saludos!
xPecie is offline
baneado
Veteran Member
Join Date: Dec 2012
Location: amxmodx-es.com
Old 07-16-2013 , 10:44   Re: [Guía] Setear modelos con Player Models API
#15

seguro que lo tienes asi

PHP Code:
// Custom models stuff
static Rand 
-->

PHP Code:
// Custom models stuff
static iRand 

Last edited by baneado; 07-16-2013 at 10:44.
baneado is offline
xPecie
Senior Member
Join Date: Dec 2012
Location: amxmodx-es.com
Old 07-16-2013 , 10:52   Re: [Guía] Setear modelos con Player Models API
#16

Depués de eso me sale todo esto:

Error: Undefined symbol "iRandom_num" on line 1709
Error: Undefined symbol "iRandom_num" on line 1875
Error: Undefined symbol "iRandom_num" on line 1889
Error: Undefined symbol "iRandom_num" on line 1903
Error: Undefined symbol "iRandom_num" on line 1917
Error: Undefined symbol "iRandom_num" on line 2124
Error: Undefined symbol "iRandom_num" on line 2130
Error: Number of arguments does not match definition on line 2136
Error: Undefined symbol "iRandom_num" on line 2147
Error: Undefined symbol "g_set_modelindex_offset" on line 2149
Error: Undefined symbol "fm_cs_set_user_model_index" on line 2149
Error: Undefined symbol "iRandom_num" on line 2153
Error: Undefined symbol "g_set_modelindex_offset" on line 2155
Error: Undefined symbol "fm_cs_set_user_model_index" on line 2155
Error: Undefined symbol "g_ent_playermodel" on line 2162
Warning: Expression has no effect on line 2162
Error: Expected token: ";", but found "]" on line 2162
Error: Invalid expression, assumed zero on line 2162
Error: Too many error messages on one line on line 2162

Por pasos:

Linea 1709: ArrayGetString(g_sky_names, iRandom_num(0, ArraySize(g_sky_names) - 1), sky, charsmax(sky))
xPecie is offline
baneado
Veteran Member
Join Date: Dec 2012
Location: amxmodx-es.com
Old 07-16-2013 , 15:04   Re: [Guía] Setear modelos con Player Models API
#17

eso es algo que modificaste tú, no tiene nada que ver con este tutorial

PHP Code:
ArrayGetString(g_sky_namesrandom_num(0ArraySize(g_sky_names) - 1), skycharsmax(sky)) 
baneado is offline
Axelromero91
Member
Join Date: Jun 2013
Location: Buenos Aires, Argentina
Old 09-16-2013 , 13:58   Re: [Guía] Setear modelos con Player Models API
#18

Esto esta hecho en zp 4.3 no? porque yo lo estoy haciendo dentro del zp 4.2 y no encuentro algunas funciones. (O.o)
Axelromero91 is offline
Send a message via MSN to Axelromero91
DiegoCS
Senior Member
Join Date: Mar 2013
Old 09-16-2013 , 17:06   Re: [Guía] Setear modelos con Player Models API
#19

Quote:
Originally Posted by Axelromero91 View Post
Esto esta hecho en zp 4.3 no? porque yo lo estoy haciendo dentro del zp 4.2 y no encuentro algunas funciones. (O.o)
DiegoCS is offline
Axelromero91
Member
Join Date: Jun 2013
Location: Buenos Aires, Argentina
Old 09-16-2013 , 17:44   Re: [Guía] Setear modelos con Player Models API
#20

Ya me parecia, pude adaptar hasta cierto punto pero despue ya no encontre las funciones y lo deje je
Igual gracias. ;)
Axelromero91 is offline
Send a message via MSN to Axelromero91
 


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 05:26.


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