public void UsePower(uint actorPtr, uint acdPtr, D3PowerInfo power) { uint flagAddress = GetAddress("UsePower_Flag"); d3.WriteObject(GetAddress("UsePower_PowerInfo"), power, typeof(D3PowerInfo)); d3.WriteUInt(GetAddress("UsePower_ActorPtr"), actorPtr); d3.WriteUInt(GetAddress("UsePower_AcdPtr"), acdPtr); d3.WriteInt(flagAddress, 1); while (d3.ReadInt(flagAddress) == 1) { Thread.Sleep(1); } }