This console command casts the spell with the specified ID on/at your currently selected target.
cast [spell id] [reference id] [source] Target Command
Spell ID | The ID of the spell you wish to cast. |
Reference ID | The reference ID of the NPC/object the spell should be cast at (the spell is casted from your current target). |
Source | The source of the spell. Either (without quotes) 'left' (to cast from left hand), 'right' (to cast from right hand) or 'voice' (to cast a shout). |
cast 0004DEE9 0078783 left
The above command would make your target cast the spell with ID '0004DEE9' ("Calm") from their left hand on the NPC/object with reference ID 0078783.
player.cast 0005312D 0078783 right
The spell ID for the Circle of Protection spell is 0005312D. The above console command would make your character cast the Circle of Protection spell from his/her right hand on the target with reference ID 0078783.