fxm wrote:Maybe mrToad needs to be able to pass an array to a procedure using a pointer only as argument.
Yes, that's what I feel I need to do, exactly! It's nice to see that it's now possible to point to an array descriptor in 1.08! (Although I didn't find the download yet; I'll try your code suggestion for 1.07) And that should do what I hoped for. But all the same,
I might be missing something.
fxm wrote:For me, I consider this rather a challenge, without judging the usefulness of the method.
You see, mrToad loves to come up with engenious solutions to problems that he didn't know already have a simple solution. Being all caught up in the fun of discovery (and it is fun indeed), he probably didn't ask for the paved road around the corner. So now, he should explain.
Lost Zergling wrote:@mrToad. I understand it is just curiosity, but I don t understand precisely what could be a goal doing this.
You probe for the practicality, and I appreciate it, because I need it. As for pointing to an array descriptor? I don't know how else to tell my entities (characters, scene backgrounds, items) which graphics array they should be pointing to. (Actually I already had something figured out, but I'm tuning up, tightening up, cutting excess code from, my game engine. Also I want to take advantage of the latest features!)
But let's keep it simple. If you had a UDT array for various characters of a game, and each one needed to point to their own array of graphics, how does the character Type connect to it without a pointer? If you look at my previous code, I'm trying to tell obj(1) to point to a certain graphics array. It can do that with a ptr to a single element, and even access elements around it, but not knowing the bounds. What if you needed a private function of obj(1) to scan through this pointed-to graphics array for some info? That's why I desired to point to the descriptor and access the bounds, to be safe checking all the elements to follow.
So, if any of that makes sense after a couple beers, let me know. And feel free to point out the "This Way" neon sign I've been missing all along. xD