PDA

View Full Version : Screen->isSolid(float,float)? [984]



lucas92
03-28-2009, 06:32 PM
I've got that function:


bool GForce()
{
if(!isSolid(Link->X,Link->Y+17))
return true;
else
return false;
}

But doesn't compile


Could not match type signature isSolid(float,float)

Why can't I pass integers? Seems like a bug to me, since in Zscript.txt, it is clearly written that isSolid take integers...

EDIT- Ahaha, I'm stupid, I didn't include Screen in front of isSolid...
But I dunno why the compiler hasn't crashed on isSolid being unidentified.. Whatever.

pkmnfrk
03-29-2009, 12:14 AM
But I dunno why the compiler hasn't crashed on isSolid being unidentified.. Whatever.

Uh, it threw an error, telling you it couldn't find a function called "isSolid". What more do you want?

Joe123
03-29-2009, 08:55 AM
Surely a compile error is what we want, and a crash error is what we don't want?