View Single Post
Old 10/12/2016, 02:53 PM   #3587
Logic_
High-roller
 
Logic_'s Avatar
 
Join Date: Jun 2015
Location: Hunter's Palace
Posts: 1,178
Reputation: 149
Default Re: Little coding questions - For general minor queries 5

Quote:
Originally Posted by PrO.GameR View Post
Directly returning strings as a function result have caused me so many problems before, specially when working alongside enums, I suggest you to make a local string in the function, use strcat to concat the name to it, and then return that local string.
I did this way before you replied and it worked. Thanks anyways.

Quote:
Originally Posted by Hansrutger View Post
Same in my case, I cannot explain why though. :/
Check my above reply.

Quote:
Originally Posted by Sreyas View Post
thats a bad coding don't do like that.Why to provide extra overhead while it is accessible directly? Keep the code optmised as possible.
Easier to write for me and optimization is not really needed everywhere or in this case, this code. Making the array const would make it faster as well as I guess?
__________________
SA-MP, G-MOD and Web hosting @ https://www.prestigesteve.com.
Logic_ is offline   Reply With Quote