while (a7.EngFun.engine_frame() != 0)
{
UpdateAcknex(); // update your acknex stuff here
Application.DoEvents(); //Add this here
}
//set your acknex window to size
Code:
//get the x/y pos
int left = System.Windows.Forms.Screen.PrimaryScreen.WorkingArea.Left;
int top = System.Windows.Forms.Screen.PrimaryScreen.WorkingArea.Top +
Program.gamePlayForm.Height;
//get the w/h
int right = System.Windows.Forms.Screen.PrimaryScreen.WorkingArea.Right;
int bottom = System.Windows.Forms.Screen.PrimaryScreen.WorkingArea.Bottom - top;
//place the position (left,top)/ (right/bottom) in vectors
a7.Vector vWinPos = new a7.Vector((a7.Var)left, (a7.Var)top, (a7.Var)0);
a7.Vector vWinSize = new a7.Vector((a7.Var)right, (a7.Var)bottom, (a7.Var)0);
//set title
String winTitle = "Engine: ";
//place the window at position (left,top)
a7.EngFun.video_window(vWinPos, vWinSize, (a7.Var)2, winTitle);
//and dont forget to close acknex engine in your form exit