Bug 4746 - models strings readed incorrectly
models strings readed incorrectly
Status: RESOLVED INVALID
Product: AMX Mod X
Classification: Unclassified
Component: Addon: Counter-Strike
trunk
PC Windows
: P3 critical
Assigned To: amxmodx-bugs@alliedmods.net
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2010-12-15 12:58 PST by foghrye4
Modified: 2013-06-15 15:07 PDT (History)
3 users (show)

See Also:


Attachments

Description foghrye4 2010-12-15 12:58:08 PST
When i compile a plugin with this code:
[code]
new const g_mdl[] = "models\santa_hat.mdl";

public plugin_precache()
precache_model(g_mdl);
[/code]
, without any errors and warnings, and try run it on my Counter-Strike, i recieve a fatal error, when map a loading.
Here is error message:
<head>Fatal error
<message box body>Mod_NumForName: models\anta_hat.mdl not found

Why first letter "s" was lost?
Also i try it with "v_ak47.mdl". Same effect.
Comment 1 Vincent Herbet [:Arkshine] 2010-12-20 12:32:47 PST
Let me guess, you have used the webcompiler to compile your plugin, right ? If so the fault is because of '\' which is used to escape characters in php. Replace '\' by '/' and you won't get this bug. I don't know if it's possible to fix the webcompiler, but it's worth to ask.
Comment 2 foghrye4 2010-12-20 12:37:41 PST
I use amx mod x package pawn compiler. Yes, '/' works without errors, thank you.

Note You need to log in before you can comment on or make changes to this bug.