Rounded variable

A wrong but easy way to deal with this is to assign the discrete observed directly to the latent continuous variable.

If you want to handle this mathematically correct, the only way I can think of is to write down the cdf of the latent variable, and write a potential function that integrate the area between the rounding boundary.
For example, say your latent variable is a Normal(mu, sd) and the observed is 4, you would assign the likelihood to this observed being log(Normal(mu, sd).cdf(4.5) - Normal(mu, sd).cdf(3.5) - Normal(mu, sd).pdf(4.5)), so that you integrate the area between [3.5, 4.5) (the range of value that would round to 4).