Scriptname SuH_spellES_teliRealm extends activemagiceffect  

ObjectReference Property SuH_sdr_portalpoint Auto 
ObjectReference Property SuH_sdr_returnpoint Auto 
ObjectReference Property SuH_sd_lostchest Auto 
ObjectReference Property SuH_sd_goldchest Auto 
MiscObject property Gold001 auto
Actor property PlayerRef auto
Actor property SuH_actor_tali auto
Cell property SuH_realm auto

Event OnEffectStart(actor akTarget, actor akCaster)
	if PlayerRef.GetParentCell() == SuH_realm
		Debug.Notification("You are already in the Succubus Realm!")
	else
		SuH_sd_lostchest.RemoveItem(Gold001, 999999)
		;SuH_sd_lostchest.RemoveAllItems(SuH_sd_goldchest)
		;SuH_actor_tali.RemoveItem(Gold001, -1)
		SuH_sdr_returnpoint.MoveTo(PlayerRef)
		PlayerRef.MoveTo(SuH_sdr_portalpoint)
	endIf
endEvent