If I make a GlobalShare class to pass around public static vars (like GraphicsDevice), do I need to initialize it somewhere?
@alphatrak how can I do that? Do I initialize the whole class in Game le something?
-
-
@DaveVoyles Since the GraphicsDevice isn't instantiated until after your Game constructor is called, I'd say set it in Initialize(). -
@alphatrak you think that is where the issue is coming from? I'll let you know shortly, when I try it out - Show replies
New conversation -
-
-
@DaveVoyles meant to say "isn't initialized"Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
@DaveVoyles@alphatrak Doesn't matter when you initialize it so much as you initialize it before you use it. Put it where makes sense to you -
@KrisWD40@DaveVoyles Right, but if he uses a static for GraphicsDevice and sets it before it's been instantiated, it will always be null. - Show replies
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.