I’m asking this because there is a scifi book I’m reading, and in the book there’s a scene where someone is communicating with a person in a spacecraft moving at lightspeed. I know their ability to communicate would probably not be possible, but let’s just put that aside for a second. Hypothetically, if you could communicate with someone moving lightspeed, would the time dilation make it so that they would appear to be moving and speaking very slowly relative to you?


This hypothetical is of the type “immovable object versus unstoppable force.” The question becomes: which of the axioms of relativity do you want to discard? Yet, once you do, you are leaving the realm of physics and entering the realm of sci-fi, in which anything may be possible.
If you want to maintain any link to our current understanding of physics, there are no hypotheticals, no ifs or buts. It’s simply not possible to have a set of laws of physics consistent with relativity as we understand it, wherein massive objects can travel at the speed of light in vacuum.
Okay well let’s just stipulate that the object is travelling close to enough to the speed of light for there to be time dilation of some sort. Or maybe the object is stationary but near a black hole or something so there is time dilation from the gravity
There is always time dilation between any two frames of references moving at nonzero speed with respect to each other. It’s generally negligible for everyday velocities, but it’s still there. You can find the degree of time dilation (and length contraction for that matter) in special relativity (i.e. ignoring gravity) by computing the gamma/Lorentz factor. For example, for 90% of the speed of light, the Lorentz factor is about 2.29.
In that case, it depends on how strong the gravitational effect is. The mathematics is a bit more complicated though. I would recommend to stick to special relativity if you’re learning about relativity as an interested layman.