Frictional Games Forum (read-only)

Full Version: Error in script... Help please
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi, I'm working on a custom story right now and everything has been working great. But I stumbled upon a little error which I cannot solve.

This is not the entire script of course, but I'm gonna write what troubles me.



void OnStart()
{
SetEntityCallbackFunc("crowbar_1", "crowbarpickup");
}

void crowbarpickup(string &in asEntity, string &in type)
{
PlaySoundAtEntity("", "attack_claw_hit.snt", "Player", 0, false);
GivePlayerDamage(30, "damage_claws2.tga", "", false); <--Problem. Script works if I delete this one.
SetPlayerActive(false);
SetPlayerCrouching(true);
SetLanternDisabled(true);
FadePlayerRollTo(75, 10, 100);
AddTimer("",0.3,"blacksout");
}


When I try to test this script, I get the error:

"main (260, 1) : ERR : No matching signatures to
'GivePlayerDamage(const uint, string@&, string@&, const bool)' "

I use Notepad++, and on Ln: 260 Col: 1, I can't really see what the problem is. I know Notepad can give you the wrong hints on where the error is, happened before. That's why I'm asking you for help. I'm heading off to bed now, and I would be the happiest man alive if some awesome person solved this til' I wake up.

Thanks in advance, pontusry.
GivePlayerDamage(30.0f, "damage_claws2", false, false);


try that
(04-01-2012, 04:42 AM)flamez3 Wrote: [ -> ]GivePlayerDamage(30.0f, "damage_claws2", false, false);


try that
I don't know who you are, but if I weren't straight, I would french kiss you against your will.

Thank you so much for the quick reply, this helped.
I don't know if I should be scared or happy regarding your comment Big Grin