Could we be living in a simulation? To be clear, we live in the real world; we are not living in a simulation.
Nick Bostrom's simulation argument is the one I am familiar with. According to Nick, if a future civilization develops and chooses to run ancestor simulations, then the odds are that we are simulated persons, rather than people in the real world. This probability is because future civilizations would have the computational resources to create many many simulations with many many simulated people (way more simulated people than there are real people).
I would definitely have a problem with being a simulated person as I think it would mean I do not have a free will. There are no computer programs that "self-code." All computer programs are deterministic. Accordingly, a simulation would also be deterministic. And in that case, if I were in the simulation I too would be deterministically programmed.
But we do have free will. Therefore, we must not be living in a simulation.
A problem with the simulation argument is that it is unclear to me why an entire civilization would choose to dedicate its resources to ancestor simulations. Not only would doing so be highly unethical and a complete waste of resources, (not to mention it would take a lot of time and resources to build this simulation) it would also be entirely pointless, given that everything that will happen in the simulation is already known, given that the simulation world is deterministic.
Additionally, I do not think consciousness can be "simulated." Only living things can be conscious, not computer programs or anything contained in computer programs.