another question!
I defined a prototype with
Prototype.i PRenderFunc(*rdrObj.RenderObject)
Now I tried to assign it:
test.PRenderFunc = @DrawSprite
test(RENDERCONT\RenderObjs())
What is the correct syntax to create this function pointer? Can function pointers also be used in lists or maps?
Search found 4 matches
- Sat Dec 16, 2023 2:44 pm
- Forum: Coding Questions
- Topic: Sorting list of structure
- Replies: 7
- Views: 841
- Sat Dec 16, 2023 2:26 pm
- Forum: Coding Questions
- Topic: Sorting list of structure
- Replies: 7
- Views: 841
Re: Sorting list of structure
Makes sense. Thx. 
- Sat Dec 16, 2023 12:25 pm
- Forum: Coding Questions
- Topic: Sorting list of structure
- Replies: 7
- Views: 841
Re: Sorting list of structure
Thanks :D , worked for me to this way.
I think I found the problem.
I was doing it like that, passing the structure objects to a procedure:
Structure RenderContainer
List *RenderObjs.RenderObject()
EndStructure
Global RENDERCONT.RenderContainer
Procedure AddRenderObject(*rdrObj.RenderObject ...
I think I found the problem.
I was doing it like that, passing the structure objects to a procedure:
Structure RenderContainer
List *RenderObjs.RenderObject()
EndStructure
Global RENDERCONT.RenderContainer
Procedure AddRenderObject(*rdrObj.RenderObject ...
- Sat Dec 16, 2023 9:10 am
- Forum: Coding Questions
- Topic: Sorting list of structure
- Replies: 7
- Views: 841
Sorting list of structure
Hi there, I started using PureBasic yesterday for the first time.
I like it so far, but I have to get used to the syntax.
But I have a weird problem here, but perhaps I am overlookign something.
I created a function to define RenderObjects by passing position to draw a sprite. )With Z I want to ...
I like it so far, but I have to get used to the syntax.
But I have a weird problem here, but perhaps I am overlookign something.
I created a function to define RenderObjects by passing position to draw a sprite. )With Z I want to ...