Index | FAQ | Search | Memberlist | Usergroups | Profile | Log in to check your private messages | Log in | Register

Checking the beginning of strings...

| Inside3d Forums Forum Index -> QuakeC Programming

View previous topic :: View next topic
Author | Message
--- | ---
Morkai Joined: 29 Mar 2008 Posts: 2 |

Posted: Sat Mar 29, 2008 3:24 pm Post subject: Checking the beginning of strings... |

Hi Everyone, (I'm new...ish) Was playing the other day with DP and QuakeC. Is there a way to check the beginning part of a string...? (was trying to implement footsteps specific to texture) eg. if the string has "METAL_" or "WOOD_" at the beginning.
I know I could do a check against all the possible texture names I have but I was trying to cut out a lot of code writing!
Thanks a bunch.

Back to top |

Morkai Joined: 29 Mar 2008 Posts: 2 |

Posted: Sat Mar 29, 2008 4:37 pm Post subject: |

Sussed it... strncasecmp etc. in the FTE_STRINGS bit of dpextensions.QC No worries!

Back to top |

CocoT Joined: 14 Dec 2004 Posts: 599 Location: Belly-Gum |

Posted: Tue Apr 01, 2008 3:46 am Post subject: |

I'm glad you find out the answer, Morkai I'm afraid I personally wouldn't have been of much help _________________ http://www.planetcocot.net/

Back to top |

Display posts from previous:

| Inside3d Forums Forum Index -> QuakeC Programming | All times are GMT
Page 1 of 1

Jump to:

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

Powered by phpBB © 2004 phpBB Group