public ErrorCodes DrawDecorEnvironment(int decorId) { DecorDescription decorDescription; if (!_decors.TryGetValue(decorId, out decorDescription)) { return(ErrorCodes.ItemNotFound); } var environmentDescription = EntityEnvironment.LoadEnvironmentSql(decorDescription.definition); if (environmentDescription.Equals(default(EntityEnvironmentDescription))) { return(ErrorCodes.DefinitionHasNoEnvironment); } ErrorCodes ec; var newTurns = -1; var flipX = false; var flipY = false; if ((ec = decorDescription.FindQuaternionRotationAndMirror(ref newTurns, ref flipX, ref flipY)) != ErrorCodes.NoError) { return(ec); } _zone.DrawEnvironmentForDecor(decorDescription.GetServerPosition(), environmentDescription, newTurns, flipX, flipY); return(ErrorCodes.NoError); }