• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

Parallax moving with camera

I have the following code for a background that moves with the mouse:

GML:
if(room == rm_Title_914){
var cam_x, cam_y;
cam_x = mouse_x-room_width/1.5;
cam_y = mouse_y-room_width/3.5;

#region ENEMY LAYER -6
if (layer_exists("BG_Color"))
{
    layer_x("BG_Color",cam_x/-10);
}

if (layer_exists("BG_Color"))
{
    layer_y("BG_Color",cam_y/-10);
}
#endregion
}
I have an instance layer with 2 objects that I want to apply this effect to. I am not sure how I would be able to do this with an instance layer.

The objects I have on that layer are rotating:
1631649178172.png
 
Top