private unsafe void ReQuestCastleWar(TPlayObject PlayObject, string sIndex) { TUserItem * UserItem; TUserCastle Castle; int nIndex; try { nIndex = HUtil32.Str_ToInt(sIndex, -1); if (nIndex < 0) { nIndex = 0; } Castle = M2Share.g_CastleManager.GetCastle(nIndex); if (PlayObject.IsGuildMaster() && !Castle.IsMember(PlayObject)) { UserItem = PlayObject.CheckItems(M2Share.g_Config.sZumaPiece); if (UserItem != null) { if (Castle.AddAttackerInfo(PlayObject.m_MyGuild, 0)) { PlayObject.SendDelItems(UserItem); PlayObject.DelBagItem(UserItem->MakeIndex, M2Share.g_Config.sZumaPiece); this.GotoLable(PlayObject, "~@request_ok", false); } else { PlayObject.SysMsg("您现在无法请求攻城!!!", TMsgColor.c_Red, TMsgType.t_Hint); } } else { PlayObject.SysMsg("您没有" + M2Share.g_Config.sZumaPiece + "!!!", TMsgColor.c_Red, TMsgType.t_Hint); } } else { PlayObject.SysMsg("您的请求被取消!!!", TMsgColor.c_Red, TMsgType.t_Hint); } } catch { M2Share.MainOutMessage("{异常} TGuildOfficial.ReQuestCastleWar"); } }