Tequila wrote:Then I tried to integrate your mod in the 1.1 branch. I got a lot of compilation problems. I look a little more on the code and here are few comments I want you to consider

1. Can you try the current 1.1 branch ?
How do I merge it with the trunk in order to compile it? There appear to be significant changes, such as q_shared being moved to qcommon.
Tequila wrote:2. Can you try then to use Q_stristr instead of adding your own stristr in cl_cgame.c ?
3. Can you check to use Q_stricmp also ?
Done, because I haven't got 1.1 compiling I placed the necessary code into cl_cgame to test it. I have now changed it to those.
Tequila wrote:...4. On which platform are you modding ? It seems mine (Linux) knows nothing of "strnset", then can you find a way to replace it ?
Windows Vista, Visual C++ Express Edition 2008. I've replaced strnset with Com_Memset.
Tequila wrote:5. Can you take a look at Sys_ListFiles and try to use the same APIs for memory allocations ?
Done, replaced with Z_Malloc and a change in method of working instead of realloc.
Tequila wrote:6. Why did you focus on a filter file ? Why not using a dedicated cvar we can edit directly in the game ? Even if we are limited in size, your cvar will be stored in standard configuration.
I didn't think of doing this, my first idea was just a file.
I've now changed it to use cg_filterWords. A much better implementation, thank you

. This has changed some of it quite a bit. I'll update the ZIP when we've sorted out the 1.1 question - if that is still necessary.
Tequila wrote:7. Why not simply discard a message which contains a badword ?
8. You should check eventually to use the Q_CleanStr API before parsing the message so you won't have color pollution.
Because perhaps it's a team game, and there may be useable information as well. I don't think I could use Q_CleanStr too easily, since I really don't think a discarding method would be good.
Tequila wrote:9. Finally, can you active compiler warnings when you build your engine ? You'll see some important casting warnings that I don't want to see before merging a code
Due to the restructuring and removing of stristr, there is no more casting and the warnings are gone

.
Tequila wrote:I can manage to remove some but that won't be your code any more then.
"My" code or not doesn't really matter - but you have more important things to be working on and this was my contribution - intended to help and not hinder active development

.