Here's some info from one of my previous answers that may be helpful to you:
Depersonalization Disorder is a Dissociative Disorder and it's characterized by a profound sense of detachment that makes you feel as though you're going through the motions of life, but not really living the experience. People describe it as feeling like they are in a fog, or almost as though they are in a dream and there's often a sense of unreality about things (derealization), although you consciously know what's real, it just doesn't feel that way. Sometimes there are alterations in your sense of space (things appear smaller or further away) or your sense of time (things seem to be speeded up or slowed down) or you may see people talking but not really hear or know what they are saying for brief moments, like in the song "Comfortably Numb" by Pink Floyd which is quite a poetic description of one presentation of the experience and dissociation generally.
Depersonalization can exist alone or as part of another disorder, most notably Panic Disorder and PTSD, but it may also be connected with depression, especially in milder form where people describe feeling numb or like their emotions are blunted or flat lined. However, actual depersonalization is usually more extreme and represents a significant sense of detachment from oneself more than just the chronic numbness that often accompanies depression.
It is also has a relationship to “trance” and can be brought on by significant periods of sleep deprivation or other “trance-inducing” activities that require extreme and prolonged focus and concentration, like addicting computer games or monotonous and routine activity, both of which I believe are related. “Trance-inducing activity” leads to an altered state where there is reduced sensitivity to your surroundings. (Just think of "highway hypnosis"-this is pretty common and normal, but lasts briefly, though it shares many of the same features)
There's a good chance that Depersonalization will resolve on its own without intervention, particularly if it’s brief and hasn’t become habitual. However, a longer duration suggests that treatment aimed at helping you reconnect with yourself may be beneficial. Often times, depersonalization becomes a chronic way of coping with overwhelmingly uncomfortable or painful feelings and disconnecting from the experience of them, hence its frequent occurrence in response to trauma. Depersonalization is a frequent and common symptom associated with PTSD and also extreme anxiety and functions as a defense against the intense feelings people experience during abuse, life-threatening circumstances and extreme anxiety and panic and protects a person from becoming completely overwhelmed. People often "trance out" when under stress, and it functions to decrease their awareness of and sensitivity to distressing experiences, like the "freeze" response seen in trauma victims. (Just think of the teenager who "tunes out" when a parent or other person is berating them with criticism-they hear it, but don't really react to it). Therapy can be especially helpful if there is a history of emotional abuse that depersonalization helps you escape as it can become a familiar and almost automatic process that gets triggered by emotional arousal. In that way, it becomes a disorder as it serves to keep a person detached from their own experiences and disconnected from their sense of self. Therapy aims at making this a less automatic process and helping people reconnect to their emotions, their body and their sense of self and learning other ways to cope and self-soothe so that dissociation is no longer a “knee-jerk” reaction to emotional triggers.
Things you can do involve grounding yourself in various ways. "Mindfulness" is excellent and is simply being in the moment and concentrating on all the sensations you are aware of in order to ground you both in the present and in your body (Eg: doing the dishes: concentrate on the temperature of the water, the smell of the dish detergent, the feel of the glass or ceramic you're holding, notice the soap bubbles, etc.) It can break the "trance" effect when you are experiencing depersonalization. Another tip is to keep your eyes moving-frequently when we are stressed and "freeze" our gaze becomes fixed, or locked, and this induces the hypnotic "trance" state. Keep your eyes moving and avoid becoming transfixed or staring at a single object. Using a journal or meditative practices that seek to connect you with yourself, being in touch with your feelings and even your physical state, as well as your emotional self, can help reconnect you and ground you. Deep breathing and progressive muscle relaxation is excellent as it treats both the disconnectedness as well as being the single most effective technique for stopping a panic attack. Hope this helps, but please seek out a therapist who can assist you further if you suffer from continued panic and depersonalization.
Vicodin is an opiate and can increase feelings of detachment, so it would make sense to me that it may have triggered an axacerbation of symptoms. High doses of sedative-hypnotics can too. It would be an uncommon side effect for an antibiotic, but perhaps your own worsening anxiety and time to dwell while recuperating during other illnesses may have contributed.
Hope this helps.
20 years as a psychotherapist with specialization in dissociative disorders