Gamestudio Links
Zorro Links
Newest Posts
Help with plotting multiple ZigZag
by degenerate_762. 04/30/24 23:23
M1 Oversampling
by 11honza11. 04/30/24 08:16
Trading Journey
by howardR. 04/28/24 09:55
Zorro Trader GPT
by TipmyPip. 04/27/24 13:50
Data from CSV not parsed correctly
by jcl. 04/26/24 11:18
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
3 registered members (AndrewAMD, Quad, M_D), 1,217 guests, and 1 spider.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Assigning on_* events(C++ Engine SDK) #461550
08/10/16 23:43
08/10/16 23:43
Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
Quad Online OP
Senior Expert
Quad  Online OP
Senior Expert

Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
Hello,

I am trying to assign some ev->on_* using the engine SDK. They seem to be simple EVENT pointers, which i tried to assign functions by casting their pointers to EVENT*, which compiles and runs fine with no crashes whatsoever but the events do not trigger.

Particular events i am trying to assign are on_resize on_d3dreset on_d3dlost.

Anyone point me in right direction?


3333333333
Re: Assigning on_* events(C++ Engine SDK) [Re: Quad] #461551
08/11/16 00:00
08/11/16 00:00
Joined: Oct 2011
Posts: 1,082
Germany
C
Ch40zzC0d3r Offline
Serious User
Ch40zzC0d3r  Offline
Serious User
C

Joined: Oct 2011
Posts: 1,082
Germany
Code:
*ev->on_anykey = (EVENT)hkOnKeyAny;


Last edited by Ch40zzC0d3r; 08/11/16 00:07.
Re: Assigning on_* events(C++ Engine SDK) [Re: Ch40zzC0d3r] #461552
08/11/16 00:40
08/11/16 00:40
Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
Quad Online OP
Senior Expert
Quad  Online OP
Senior Expert

Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
tried that too still on_resize and on_1 etc still not firing.

Okay dammit, i forgot managed the message loop myself.

Last edited by Quad; 08/11/16 00:41.

3333333333
Re: Assigning on_* events(C++ Engine SDK) [Re: Quad] #461553
08/11/16 01:01
08/11/16 01:01
Joined: Oct 2011
Posts: 1,082
Germany
C
Ch40zzC0d3r Offline
Serious User
Ch40zzC0d3r  Offline
Serious User
C

Joined: Oct 2011
Posts: 1,082
Germany
If those events dont work you can simply hook the directx function.
Its called Reset() and its vtable index is 16

Re: Assigning on_* events(C++ Engine SDK) [Re: Ch40zzC0d3r] #461562
08/11/16 08:58
08/11/16 08:58
Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
Quad Online OP
Senior Expert
Quad  Online OP
Senior Expert

Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
I added video_set to WM_SIZE handler and added original engine message loop to the end of my custom one and use on_d3d* messages. It kind of works fine except i have to find a way to determine when to handle the input on my own or let the engine handle it.


3333333333

Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1