/** * 领取首付礼包 */ const cmd_pay_getfirstpaygift = 8802; // //---------- 移动端 支付API 操作码 ---- /** * 【移动端】购买物品 */ const cmd_mpay_pay = 8807; /** * 【移动端】查询游戏币余额 */ const cmd_mpay_get_balance = 8808; /** * 【移动端】购买神秘商城物品 */ const cmd_mpay_buyDynamic = 8809; /** * 【移动端】刷新神秘商城物品 */ const cmd_mpay_getDynamic = 8810; /** * 【移动端】自助检查异常订单 */ const cmd_mpay_selfCheckOrders = 8811; /** * 【移动端】查询付费记录 */ const cmd_mpay_getPayRecords = 8812; /** * 临时--正式的要根据具体功能实现 */ const cmd_mpay_PayDeliverGoods = 8813; /** * 充值领取奖励 */ const cmd_mpay_UserRechargeDrawPrize = 8814; /** * 新的首冲功能 */ const cmd_mpay_NewFirstRecharge = 8815; // // // // // // // /** * 获取分区列表 */ const cmd_user_getzonelist = 6000; /** * 玩家登录指令 */ const cmd_user_loginuserinfo = 6001; /** * 常量信息指令 */ const cmd_user_gameconstinfo = 6002; /** * 获取连续登录奖励 */ const cmd_user_acceptcontidaysgift = 6003; /** * 更新玩家新手引导的进度 */ const cmd_user_registerNewUID = 6004; /** * 【测试】机器码登录 */ const cmd_user_testUserLogin = 6005; /** * 注册新用户 */ const cmd_user_registerNewRole = 6006; /** * 完成新手引导 */ const cmd_user_completeNewbieGuide = 6007; /** * [6008] 发放新手引导所需卡牌 */ const cmd_user_setNewbieGuideCards = 6008; /** [609] * 新手引导——设置结束标志位 */ const cmd_user_setNewbieGuideOver = 6009; /** * [6010] 设置/修改玩家昵称 */ const cmd_user_setNickname = 6010; /** [6011] * 修改头像框 */ const cmd_user_SetUserHeadImageBorder = 6011; /** * 更换玩家形象 */ const cmd_user_setUserImage = 6012; /** * 更换玩家头像 */ const cmd_user_changeUserHeadImg = 6013; /** * 6014 初始化火山引擎 */ const cmd_user_stat_initvolc = 6014; /** * 6015 收集玩家意见和bug */ const cmd_user_ctxBack = 6015; /** * 6016 查询其他玩家信息 */ const cmd_user_other_info = 6016; /* * 删除角色 */ const cmd_user_deleteUserUId = 6017; // // // /** * [6101]申请好友 */ const cmd_user_friend_apply = 6101; /** * [6102]同意成为好友 */ const cmd_user_friend_accept = 6102; /** * [6103]拒绝好友申请->?这里需不需要通知被拒绝人? */ const cmd_user_friend_deny = 6103; /** * [6104]解除好友关系 */ const cmd_user_friend_remove = 6104; /** * [6105]拉取好友请求列表 */ const cmd_user_friend_getapplylist = 6105; // --------- 好友列表 ------------- /** * [6106] 拉取好友列表 */ const cmd_user_friend_get_list = 6106; /** * [6107] 拉取好友详细信息(分批次) */ const cmd_user_friend_get_infos = 6107; //----------消息-------------------- /** * [6108] 给好友发送消息 */ const cmd_user_friend_leave_message = 6108; /** * [6109] 拉取最新好友消息 */ const cmd_user_friend_get_message = 6109; //------------查找---------------------- /** * [6110]搜索好友 */ const cmd_user_friend_search = 6110; /** * [6111]系统推荐好友列表(添加好友面板适用) */ const cmd_user_friend_suggestList = 6111; // ---------------刷新-------------------- /** * [6112] 重新载入好友模块(刷新好友模块,该删除的删除,该添加的添加) */ const cmd_user_friend_reload = 6112; /** * [6113] 拉取好友向我赠送礼物的记录 */ const cmd_user_friend_gift_getlist = 6113; /** * [6114] 领取礼物 */ const cmd_user_friend_gift_redraw = 6114; /** * [6115]向好友示好(如浇水,送花之类的表现) */ const cmd_user_friend_gift_send = 6115; /** * [6116]请求查看玩家是否有未读信息 */ const cmd_user_friend_unduckmsg = 6116; /** * [6117]请求查看玩家公会信息 */ const cmd_user_friend_LookGuildInfo = 6117; /** * [6118]请求查看玩家简介 */ const cmd_user_friend_LookFriendInfo = 6118; // // // /** * [6201] 任务 - 拉取最新任务信息 */ const cmd_task_getInfo = 6201; /** * [6202] 任务 - 领取任务奖励 */ const cmd_task_getReward = 6202; /** * [6203]普通任务 - 设置关注任务 */ const cmd_Task_setAttentionTask = 6203; /** * [6204]日常任务 - 领取活跃度奖励 */ const cmd_Task_getActiveReward = 6204; // // /** * 任务卡 - 剧情触发任务结束 */ const cmd_taskCard_PlotFinish = 6210; /** * 任务卡 - 剧情回收任务卡 * @deprecated since version 2020.12.12 */ const cmd_taskCard_PlotExchangeTaskCard = 6211; /** * 任务卡 - 剧情赠与任务卡 * @deprecated since version 2020.12.12 */ const cmd_taskCard_PlotPresentTaskCard = 6212; /** * 任务卡 - 即时结算 * @deprecated since version 2020.12.12 */ const cmd_taskCard_FinishAndReward = 6213; /** * 任务卡 - 杀死怪物事件 */ const cmd_taskCard_onKillMonster = 6214; /** * 任务卡 - 激活 */ const cmd_taskCard_active = 6215; /** * 任务卡 - 领取奖励 */ const cmd_taskCard_reward = 6216; /** * 任务卡 - 更新信息 */ const cmd_taskCard_info = 6217; /** * 任务步骤 - start/finish action完成 */ const cmd_taskCard_StepActionDone = 6218; /** * [6219]任务追踪-设置当前追踪 */ const cmd_Task_setTracingCard = 6219; /** * [6220] 任务步骤 - 回档重置 */ const cmd_task_StepFallBack = 6220; // // // // /** * 任务卡商城 - 开启商店 */ const cmd_taskcard_shop_open = 6231; /** * 任务卡商城 - 购买 */ const cmd_taskcard_shop_buy = 6232; /** * 任务卡商城 - 手动刷新 */ const cmd_taskcard_shop_refresh = 6233; // // // // // /** * 英雄 - 升级 * ::= 消耗金币和碎片进行升级 */ const cmd_hero_levelup = 6301; /** * 英雄 - 加上装备 */ const cmd_hero_equip = 6302; /** * 英雄 - 卸下装备 */ const cmd_hero_unequip = 6303; /** * 英雄 - 升阶 :: 消耗碎片 */ const cmd_hero_stageup = 6304; /** * 英雄- 升星 */ const cmd_hero_upstar = 6305; /** * 英雄- 更改锁定状态 */ const cmd_hero_changelockstate = 6306; /** * 英雄- 更改好友支援状态 */ const cmd_hero_changefirendbackup = 6307; /** * 英雄---获得 一个英雄 */ const cmd_hero_gethero = 6308; /** * 英雄的突破升级 */ const cmd_hero_strength = 6309; /** * 英雄的解锁好感度 */ const cmd_hero_openFavor = 6310; /** * 英雄的分解获得好感度晶石 */ const cmd_hero_separate = 6311; /** * 购买玩家可以收集的英雄的数量上限 */ const cmd_hero_buyCollectHeroLimtCount = 6312; /** * 更改好友支援 */ const cmd_hero_changefriendsupport = 6313; /** * 英雄的技能升级 */ const cmd_hero_upgradeSkillLevel = 6314; /** * 存储队伍配置 */ const cmd_hero_saveHeroTeamConfig = 6315; /** * 拉取英雄评论列表 */ const cmd_hero_GetDiscuss = 6316; /** * 对英雄发表评论 */ const cmd_hero_PostDiscuss = 6317; /** * 给某条评论点赞 */ const cmd_hero_PraiseDiscuss = 6318; /** * 删除对某个英雄的评论 */ const cmd_hero_DeleteDiscuss = 6319; /** * 给某个英雄打分 */ const cmd_hero_scoreit = 6320; /** * 购买英雄 */ const cmd_hero_buyHero = 6321; /** * 英雄神血升级 */ const cmd_hero_upGodBlood = 6322; /** * 英雄碎片 先解锁 再购买 */ const cmd_hero_unlockByPieces = 6323; /** * 英雄技能 - 解锁技能 */ const cmd_hero_unlockSkill = 6324; /** * 英雄技能 - 一键升级 */ const cmd_hero_skillLevel_onekeyupgrade = 6325; /** * 升星 */ const cmd_hero_StrengthenStar = 6326; /** * 言灵升级 */ const cmd_hero_YanlinUpLevel = 6327; /** * 唤灵师突破 */ const cmd_hero_tupo = 6328; /** * 言灵替换 */ const cmd_hero_YanLingReplace = 6329; /** * 召唤言灵 */ const cmd_hero_zhaohuanYanLing = 6330; // // // /** * 放入仓库 */ const cmd_store_put = 6401; /** * 卖出单个物品 */ const cmd_store_singleSell = 6402; /** * 从背包批量卖出物品 */ const cmd_store_mutliSell = 6403; /** * 使用物品 */ const cmd_store_use = 6404; /** * 刷新仓库 */ const cmd_store_refresh = 6405; /** * 删除道具 */ const cmd_store_delItem = 6406; /** * 测试用的命令 */ const cmd_store_Testcmd = 6407; /** * 升级某个装备 */ const cmd_store_ItemUpgrade = 6408; /** * 宝石合成 */ //const cmd_store_GemCompose = 6409; /** * 英雄穿装备 */ const cmd_store_WearEquip = 6410; /** * 英雄脱装备 */ const cmd_store_UnWieldEquip = 6411; /** * 购买增加物品栏格子数 */ const cmd_store_AddMaxPacketNum = 6412; /** * 装备熔炼 */ const cmd_store_MeltEquip = 6413; /* * * * 碎片合成 */ const cmd_store_PiecesCompose = 6415; /** * 装备言灵 */ const cmd_store_WearYanling = 6416; /** * 卸下言灵 */ const cmd_store_UnWieldYanling = 6417; /** * 言灵召唤书碎片合成召唤书 */ const cmd_store_mergeYanlingbook = 6418; /** * 利用言灵召唤书召唤言灵 */ const cmd_store_callyanling = 6419; /** * 言灵进阶---废弃 */ const cmd_store_yanling_upgrade = 6420; /** * 武器升级 */ const cmd_store__weapon_upgrade = 6421; /** * 武器突破 */ const cmd_store__weapon_tupo = 6422; /** * 武器替换 */ const cmd_store_weaponReplace = 6423; /** * 宝石合成 */ const cmd_store_GemCompose = 6424; /** * 宝石研究等级提升 */ const cmd_store_GemResearchLvUp = 6425; /** * 宝石镶嵌 */ const cmd_store_GemSet = 6426; /* * 宝石卸下 */ const cmd_store_GemRemove = 6427; /** * 背包扩展 */ const cmd_store_unlockStore = 6428; /** * 购买武器 */ public const cmd_store_buyWeapon = 6429; /** * 获取商店武器信息 */ public const cmd_store_getShopWeapon = 6430; /** * */ public const cmd_store_buySupplies = 6431; /* * 扩容第三个格子 */ public const cmd_store_expandStorage = 6432; /* * 放入和移除储物间 */ public const cmd_store_changeStorage = 6433; /** * 添加、移除血瓶 */ public const cmd_store_changeBettleItem = 6434; /* * 道具全部使用,删除 */ public const cmd_store_useBettleItem = 6435; /** * 血瓶或蓝瓶自动使用条件设置 */ public const cmd_store_setBettleItemUseVal = 6436; /** * 删除所有类型道具 */ public const cmd_store_removeItem = 6437; /* * 击杀怪,唤灵师获得的信息加成,暂时是经验 */ public const cmd_store_killMosterAddData = 6438; /** * 查看新道具 */ public const cmd_store_refreshItem = 6439; /** * 言灵进化 */ public const cmd_store_yanlingEvolve = 6440; /** * 一键进化 */ public const cmd_store_yanlingEvolve_overall = 6441; /** * */ public const cmd_store_setBettleItemAutoVal = 6442; /** * 从前段更新到后端战力值 */ public const cmd_store_UpdateFightPower = 6443; // // // // /** // * 开服七日活动 - 刷新任务列表 // */ // const active_day7_gettasklist = 6500; // /** * 活动 - 等级奖励: 领取奖励 */ const active_levelgift_getReward = 6501; // /** * 开服七日活动 - 领取奖励 */ const active_day7_drawreward = 6502; /** * 查询开服时间 */ const active_getzonePublicTs = 6503; /** * 查询当日在线时长信息 */ const active_getTodayOnlineInfos = 6504; // /** // * 神庙抽奖 // */ // const active_shenmiaoDrawPrize = 6505; // /** // * 普通任务 - 完成任务 // */ // const Task_completetask = 6506; // // /** // * 普通任务 - 领取奖励 // */ // const Task_drawreward = 6507; /** * 领取体力,间隔领取体力 */ const Task_Tili = 6508; // /** // * 活动 - 抽奖 // */ // const lottery = 6509; // // /** // * 新手引导 - 活动-抽奖 // */ // const lottery_demo = 6510; // // /** // * 活动 - 抽奖 领取保底奖励 // */ // const lottery_baodi = 6511; /** * 活动 - 凭兑换码领取礼包 */ const active_token_drawReward = 6512; /** * 活动 - 领取在线礼包 */ const active_draw_onlinegift = 6513; /** * 活动 - 领取全服注册礼包 */ const active_draw_reggift = 6514; /** * 活动 - 加油站: 领取在线赠送体力 */ const active_presentTili = 6515; /** * 活动 - 查询当前全服注册人数 */ const active_get_regnum = 6516; /** * 开宝箱-减少冷却时间 */ const box_SubCoolDown = 6517; /** * 购买体力 */ const active_BuyTili = 6520; /** * 刷新当前体力 */ const active_GetCurTili = 6521; /** * 金币兑换活动 */ const active_goldexchange = 6522; // // // // /** * 排行榜 - 战斗力榜 */ const rank_fpower_getRank = 6601; /** * 排行榜 - 领取战斗力榜突破奖励 */ const rank_fpower_drawReward = 6602; /** * 排行榜 - 查询玩家战斗力排名 */ const rank_fpower_getRanking = 6603; /** * 排行榜 - 查询各榜榜一 */ const rank_getTop1 = 6604; /** * 排行榜 - 通关榜 */ //const rank_passgate_getrank = 6605; /** * 排行榜--玩家等级榜信息 */ const rank_playerlevel_getrank = 6605; /** * 排行榜 - 领取通关榜突破奖励 */ const rank_passgate_drawReward = 6606; /** * 排行榜 - 查询战力突破记录 */ const rank_fpower_breachLog = 6607; /** * 排行榜 - 查询通关榜突破记录 */ const rank_passgate_breachLog = 6608; // // // // /** * [6701]获取邮件列表 */ const cmd_email_questEmailList = 6701; /** * [6702]读取/打开一封邮件 */ const cmd_email_readAEmail = 6702; /** * [6703] 邮件 - 领取附件 */ const cmd_email_DrawReward = 6703; /** * [6704] 邮件 - 领取全部附件奖励 */ const cmd_email_DrawAllRewards = 6704; /** * [6705] 删除邮件——所有已读(不包含已读未领取状态的邮件) */ const cmd_mail_delMailReaded = 6705; /** * [6706] 请求邮件未处理的数量(未打开邮件时检查邮件图标应该提示啥) */ const cmd_mail_notReadMailNum = 6706; /** * [6707] 发送测试用道具 */ const cmd_mail_sendTestItems = 6707; // const // // // /** * 关卡战斗-预掉落计算 */ const cmd_fight_arenas_preFight = 6800; /** * 关卡战斗 */ const cmd_fight_arenasfight = 6801; /** * 关卡扫荡 */ const cmd_fight_arenassweep = 6802; /** * 挑战 - 获得挑战对手的信息 */ const cmd_fight_GetChallengeAdversaryInfo = 6803; /** * 挑战 - 记录挑战结果 */ const cmd_fight_LogChallengeResult = 6804; /** * 挑战 - 拉取挑战记录 */ const cmd_fight_GetChallengeLog = 6805; /** * 剧情 - 领取剧情任务章节星数奖励 */ const cmd_fight_GetArenasActiveReward = 6806; // // // /** * 竞技场 主界面信息 */ const cmd_fight_pvp_maininfo = 6810; /** * 竞技场 刷新对手列表 */ const cmd_fight_pvp_refresh = 6811; /** * 竞技场 挑战xx. */ const cmd_fight_pvp_pk = 6812; /** * 竞技场 调整阵容 */ const cmd_fight_pvp_setTeam = 6813; /** * 竞技场 购买挑战票 */ const cmd_fight_pvp_buyTicket = 6814; /** * 竞技场 查看榜单 */ const cmd_fight_pvp_getrank = 6815; /** * 竞技场 查询战报 */ const cmd_fight_pvp_getLog = 6816; // // // // /** * 竞技场 商店 主界面信息 */ const cmd_fight_pvpShop_getMainInfo = 6820; /** * 竞技场 商店 购买道具 */ const cmd_fight_pvpShop_buy = 6821; /** * 竞技场 商店 刷新道具 */ const cmd_fight_pvpShop_refresh = 6822; // // // /** * 世界boss - 进入 */ const fight_worldBoss_enter = 6831; /** * 世界boss - 上报伤害 */ const fight_worldBoss_addDamage = 6832; /** * 世界boss - 查询boss剩余血量 */ const fight_worldBoss_refresh_blood = 6833; /** * 世界boss - 查询当前伤害榜(前x名) */ const fight_worldBoss_refresh_rank = 6834; /** * 世界boss - 查询boss输出伤害列表 */ const fight_worldBoss_refresh_bossSkill = 6835; // // // // // /** * 无尽塔 - 查询当前层 */ const fight_endlessTower_Get = 6841; /** * 无尽塔 - 前进 */ const fight_endlessTower_Up = 6842; /** * 无尽塔 - 领取成就奖励 */ const fight_endlessTower_drawreward = 6843; /** * 满血复活 */ const fight_fullBlood = 6844; // // // // // /** * 获取系统消息列表 */ const cmd_system_getsysmessage = 6901; /** * 系统日志上报 */ const cmd_system_logreport = 6902; /** * 客户端心跳包 */ const cmd_system_clienttick = 6903; /** * 玩家发送系统消息 */ const cmd_system_userSendsysmessage = 6904; // // // // /** * 【会员】查询自己的公会信息 */ const cmd_guild_getUserGuildInfo = 7000; /** * 查询公会列表 */ const cmd_guild_getList = 7001; /** * 查询 推荐公会列表 */ const cmd_guild_refuseGuildCupScore = 7002; /** * 搜索 公会 */ const cmd_guild_searchGuildByID = 7003; /** * 创建公会 */ const cmd_guild_create = 7004; /** * 申请加入 */ const cmd_guild_apply = 7005; /** * 一键加入 */ const cmd_guild_QuickIn = 7006; /** * 请求公会信息 */ const cmd_guild_GetGuildInfo = 7007; /** * 编辑 */ const cmd_guild_modifyDeclare = 7008; /** * 解散 */ const cmd_guild_dismiss = 7009; /** * 开除 */ const cmd_guild_fireMember = 7010; /** * 审批 */ const cmd_guild_approve = 7011; /** * 转让副会长 */ //const cmd_guild_transferChair = 7012; /** * 设置副会长 */ const cmd_guild_setPriceChairman = 7013; /** * 获取成员信息 */ const cmd_guild_getGuildMembers = 7014; /** * 设置 干部职位 */ const cmd_guild_setOfficer = 7015; /** * 退会 */ const cmd_guild_quit = 7016; /** * 发起弹劾 */ const cmd_guild_InitiateAccuse = 7017; /** * 同意弹劾 */ const cmd_guild_Accuse = 7018; /** * 会长取消本次弹劾 */ const cmd_guild_ChairmanCancelAccuse = 7019; /** * 申请者玩家简介 */ const cmd_guild_ApplyUserIntro = 7020; /** * 发起捐献 */ const cmd_guild_requestDonate = 7021; /** * 捐献 */ const cmd_guild_donate = 7022; /** * 捐献数据刷新 */ const cmd_guild_donateInfoRefresh = 7023; /** * 购买捐献度 礼包 */ const cmd_guild_buyDonateGift = 7024; /** * 购买公会钻石 礼包 */ const cmd_guild_buyGuildCashGift = 7025; /** * 公会公告 */ const cmd_guild_announcement = 7026; /** * 公会邮件 */ const cmd_guild_noticeMail = 7027; /** * 【公会战】 邀请成员战斗 */ const cmd_guild_vsFightInvite = 7028; /** * 【公会战】 取消邀请 */ const cmd_guild_cancelInvite = 7029; /** * 【公会战】 接受,战斗 */ const cmd_guild_fight = 7030; // const // // // // /** * 限购礼包主界面 */ const shop_limit_maininfo = 7101; /** * 购买限购礼包 */ const shop_limit_buy = 7102; /** * 月卡信息 */ const shop_monthlyVIP_Info = 7103; /** * 购买月卡 */ const shop_monthlyVIP_Buy = 7104; /** * 获取每日特惠信息 */ const shop_getDaliySpecial = 7105; /* * 获取充值返利信息 */ const shop_getRechargeRebate = 7106; /** * 日常商城购买 */ const shop_dailyShopBuy = 7107; // // // // /** * 查询角标事件通知 */ const cmd_event_GetNotifications = 7201; /** * 清理指定角标 */ const cmd_event_ClearNotifications = 7202; // // /** * 激活某任务卡 */ const cmd_college_ActiveTaskCard = 7301; /** * 领取任务卡奖励 */ const cmd_college_ReceiveCollegeReward = 7302; /** * 领取课程奖励 */ const cmd_college_ReceiveCourseReward = 7303; /** * 积分兑换道具 */ const cmd_college_ScoreExchangeItem = 7304; /** * */ const cmd_college_GetCollegeData = 7305; /** * */ //const cmd_college_GetCollegeTaskCardData = 7305; // // /** * 获取全部拍卖信息 */ const cmd_Auction_GetUserAuctionItemsInfo = 7401; /** * 玩家上架拍品信息 */ const cmd_Auction_GetUserUploadAuctionItems = 7402; /** * 玩家竞拍信息 */ const cmd_Auction_GetUserAuctionItems = 7403; /** * 一口价 */ const cmd_Auction_BuyoutPrice = 7404; /** * 取消出售 */ const cmd_Auction_CancelAuction = 7405; /** * 上传拍品 */ const cmd_Auction_UploadAuctionItems = 7406; /** * 竞拍 */ const cmd_Auction_UserAuctionBidItem = 7407; // // // // /** * 进入据点 */ public const map_EnterFootHold = 7501; /** * 开启传送阵 */ public const map_FixUpTransmission = 7502; /** * 更新探索度 */ public const map_UpdateExplorerationProgress = 7503; /** * 解锁据点 */ public const map_UnlockMap = 7504; // /** // * 获取100_0_0_时间戳这些已经解锁保存了的数据 // */ // public const map_getUnlockInfoList = 7505; /** * 100_0_0_时间戳保存 */ public const map_unlockInfoSva = 7505; /* * 领取探索奖励 */ public const map_reviceExplorerReward = 7506; /* * 回城券使用 */ public const map_huichengQuanUse = 7507; /* * 回城券传送阵消失 */ public const map_huichengQuanEnd = 7508; // // // // // /** * 辅助方法, 将所有错误码信息转换到CSV文本中. * 用法: 先在本文件中用ctrl + H 全部替换掉 'c onst ' -> 's tatic $' * 然后再调用本方法,即可在同目录下生成ErrCode.txt, 里面包含了所需信息. * @throws \Exception * @author gwang */ static function L() { $class = new \ReflectionClass(__CLASS__); # 建立这个类的反射对象 $properties = $class->getProperties(\ReflectionProperty::IS_STATIC); # 拉取所有静态属性 $fileName = __DIR__ . "/" . str_replace('\\', '.', __CLASS__) . ".txt"; # 输出文件名 $fd = fopen($fileName, "w"); if (false === $fd) { # 打开文件失败 throw new \Exception("打开$fileName 失败"); } foreach ($properties as &$p) { $d = preg_replace('/[\*|\/|\s+]/', '', $p->getDocComment()); # 处理下注释 $type = (strpos($p->getName(), 'err') === false ? 0 : 1); # errorType: 0 继续, 1 重启 $n = fputs($fd, $p->getName() . ";" . $p->getValue() . ";$type;$d" . PHP_EOL); # 写入文件 if (false === $n) { # 写入时失败 throw new Exception("写入$fileName 时失败"); } } fclose($fd); } // }