Hi there, for our game we need to create several buildings at the mousepointer ala command and conquer. Now the manual for gamestudio doesn't provide enough information on how to do this. Can anyone help my projectgroup with this by providing some code or linking a manual? This is what we have so far
Code:
function buildbuilding
{
var buildingspawnpos[3] = mouse_pos.x, mouse_pos.y, -500;
if(mouse_left == 1)
{
ent_create( "witch.MDL", buildingspawnpos, NULL );
}
}
We also have buttons that can be pressed, so we can detect the mouse pos. We use a panel to spawn these buildings, but so far we can only spawn them if we imput coordinates, other than 'mouse_pos.x and mouse_pos.y'.