Sign in to follow this  
bigbrother2000

unable to use initialised structure during render

Recommended Posts

hi, i've created a two dimensional array which has individual variables for each member, they have been initialised when directx is initialised and it finds these no problem: (firstmaze.maze[9][7].north = 1) with .north been the variable set to 1, however when i try to retrieve information during the render function of my maze array, if (firstmaze.maze[9][7].north == 1) it says .north must have a class/struct/union type and that firstmaze and maze need defining. Is there a way i access information held in the 2dimensional array during render?

Share this post


Link to post
Share on other sites
You must make sure the firstmaze object was declared and defined in the same scope of your render function (or must be global) or if u use classes
then it must be a member of the class implementing the render function.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this