How to access variables from the main sketch to in the child class?

You would need to pass it into the instance of your child class via a setter function. Something like this:

for(Collectable collectable : col) {
  collectable.setGameCharWorldX(gameChar_world_x);
}

Alternatively, you could pass an instance of your sketch (in your case, Malo1) into your child class constructor, and then you should be able to reference the variable through your sketch instance.