N
NoFontNL
Guest
Hi, I've tried to make a restart button and make it like 8 pixels from the top of the view and 8 pixels from the left of the view. So this was my try:
But it seems, it just sets the x y position once, or it doesn't see the camera x and y pos moving.
I used the Smooth Camera tutorial from Shaun Spalding.
Code:
/// obButtonRestart :: Step Event :: Positioning part.
if (instance_exists(obCamera)) { // If there is a camera,
x = camera_get_view_x(view_camera[0])+8; // then set the x to the camera's x position +8 and
y = camera_get_view_y(view_camera[0])+8; // set the y to the camera's y position + 8
} else { // if there is no camera,
x = 8; // Just set the x to 8
y = 8; // same for y.
}
I used the Smooth Camera tutorial from Shaun Spalding.