hi,
I want to use the windows's UI in the game,ex window,button,list box,checkbox and so on,I use delphi write a function in dll file:
h := GetForegroundWindow;
Form1:=TForm1.CreateParented(h);
form1.ShowModal;
setwindowpos(form1.Handle,hwnd_topmost,0,0,0,0, swp_nosize or swp_nomove);
form1.Free;then call it in the script:
external "D:\Program Files\Borland\Delphi6\Projects\dll.dll" TestDll(int);
...
TestDll(55);
...it works like:
here is the problem,sometime the showmodle window open and show back of the game surface,sometime it's open and show front of the game surface.
how can i open and show the window front of the game surface always?