[LibGdx] unknown error but it still works

Hello everyone,
yesterday i stared to learn LibGdx, i set it up and read the Wiki and the examples and now am following one of the link on the LibGdx home page
and for some reason i don’t know why this line of code is red-underline

return new SplashScreen( this );

(it’s in the first class of the blog )
i also tried to watch this video (i don’t really like video tutorials)
and he did the same, and again it’s red-underlined
the weird thing is when i run the “game”, i get the same results just like in the tutorials

any help please ??

PS :
if anyone have a better starting tutorials,articles, or even videos then please post a link here
(my favorite Java Tutorials was the one from ZetCode , so you may have an idea of my favorite “type” )

thank you very much

If you are using Eclipse and your code has a red or yellow underline, you can hover your mouse over the line to see what the error is. :slight_smile:

Lots of other tutorials mentioned here:
http://libgdx.badlogicgames.com/documentation.html

oh :smiley:
it said

[quote]The constructor SplashScreen(AngryMasons) is undefined
[/quote]
and when i click the “lamp” it said

[quote]No suggestions available
[/quote]
i don’t know if am too sleepy now or it’s a difficult error that i cannot understand :stuck_out_tongue:
help please ::slight_smile: ??

thank you

[quote]It would be nice to separate the code based on the screen. In order to achieve that in libgdx, we could modify our game’s main class to extend com.badlogic.gdx.Game
[/quote]

yes i read that,
but i completely have no idea you know :stuck_out_tongue:

Ps :
did i rushed when i post this topic ? i just start libGdx yesterday, i think i should read more about it and just follow examples for now, and then i’ll start to ask questions

Thanx for your help

I had errors like that in eclipse, try just repasting the whole entire code. Eclipse has random errors like that xD

Probably because the type you are giving to your SplashScreen constructor (“AngryMasons”) does not match the type expected, based on the constructor you defined in the SplashScreen class.

@Agro I hate when I get errors like that and it turns out eclipse was lying the whole time! Sometimes i get dissapointed when a copy and paste doesn’t solve my problems:(

If you made it extend Game then it should be fine.

i copied the code, still red-underlined, but it works too
i dunno am not very focusing with LibGdx for now (need to complete the Java2D game that i started )

thank you all