Forum

> > CS2D > Scripts > error attemp call ni value
Forums overviewCS2D overview Scripts overviewLog in to reply

English error attemp call ni value

4 replies
To the start Previous 1 Next To the start

old error attemp call ni value

superpegamento
User Off Offline

Quote
to say a word appears this error in console

error attemp call ni value
error attemp call ni value
error attemp call ni value
error attemp call ni value
error attemp call ni value

it can be?

old Re: error attemp call ni value

Rainoth
Moderator Off Offline

Quote
Dude. You are running a script.
That script is asking for a non existing thing or tries to call it.

Attempt to call a nil value means
"I'm trying to use something that doesn't exist"

If it's a plain error like that. It's probably that you added a hook but gave it no function. Like e.g. you made

1
2
3
addhook("say","potato1")
function potato2(id,t)
end

You name function potato2 but your hook calls potato1 and this way you will always get an error.

old Re: error attemp call ni value

Bowlinghead
User Off Offline

Quote
1
2
3
if v==1 then
	msg("v is 1")
end
If you write it, then you´ll get the same error, because "v" does not exist. It is not automatic 0!

1
2
3
4
v=0
if v==1 then
	msg("v is 1")
end

Now you´ll get no error.
To the start Previous 1 Next To the start
Log in to reply Scripts overviewCS2D overviewForums overview