Raised This Month: $ Target: $400
 0% 

checking strings in player step walk speed.


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
.Dare Devil.
Veteran Member
Join Date: Sep 2010
Old 04-20-2013 , 17:27   checking strings in player step walk speed.
Reply With Quote #1

Basically what ive done is that i have created new footstep sound system.
There is also now new point entity in valve hammer what allow set for texture footstep sound type.
by this is push all texturenames inside cellarray and check them if its needed
( when step sound will be playd )

As i can see valve did this system that way that they will check only first letter of texture name, now im worried.
Is it bad to check like 50 or more textures in player walking speed?
code:
PHP Code:
// texname hold texture name where player standing in
// im hold textures for checking...
            
static im[32], aiaeabacarab 0ar 0
            ac 
pn_get_size(texname// ilen
            
pn_print1"size %d"ac )
            for( 
ai 0ai Arraysize(i_m_name); ai++ )
            {
                
ArrayGetStringi_m_nameaiim31 )
                for( 
ae 0ae 31ae++ )
                {
                    if( 
ab == ac ) { ar 1; break; }
                    if( !
texname[ae] ) break
                    if( 
texname[ae] == im[ab] ) ab++
                    else break
                }
                
                if(
ar) { ps_m[id] = ArrayGetCelli_m_typea);  break; }
            }
        } 
Edit:
Oh yeah, and player can run very fast.
My soundsystem will play sound exactly when player foot touch the ground so if player maxspeed is like 600 then sound will be playing like mayby 5 times in one sec.

This system will be so good for mapper i just really need some feedback.
Thanks!

Last edited by .Dare Devil.; 04-20-2013 at 17:33.
.Dare Devil. is offline
Old 04-29-2013, 16:24
.Dare Devil.
This message has been deleted by YamiKaitou. Reason: wait 14 days before you bump
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 10:49.


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