yingxion work
This commit is contained in:
		
							parent
							
								
									fbd01f4fe6
								
							
						
					
					
						commit
						cd292a016c
					
				
							
								
								
									
										
											BIN
										
									
								
								Pasted image 20250312161024.png
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								Pasted image 20250312161024.png
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							| After Width: | Height: | Size: 34 KiB | 
							
								
								
									
										
											BIN
										
									
								
								Pasted image 20250312161120.png
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								Pasted image 20250312161120.png
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							| After Width: | Height: | Size: 34 KiB | 
							
								
								
									
										
											BIN
										
									
								
								Pasted image 20250319132136.png
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								Pasted image 20250319132136.png
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							| After Width: | Height: | Size: 66 KiB | 
| @ -6,6 +6,14 @@ | ||||
| 
 | ||||
| [AndroidDevTools](https://www.androiddevtools.cn/) | ||||
| 
 | ||||
| # 安装 | ||||
| - 先安装JDK环境 | ||||
| 	- 新版JDK已不默认集成JRE | ||||
| 	- 需要手动添加 | ||||
| 		- bin/jlink.exe --module-path jmods --add-modules java.desktop --output jre | ||||
| - Android studio setup出现 Unable to evaluate [error: 1812] | ||||
| 	- 权限不足,已管理员权限运行 | ||||
| 
 | ||||
| # 配置 | ||||
| 
 | ||||
| ## Android Studio 使用 | ||||
|  | ||||
| @ -6,10 +6,127 @@ modification date: 星期三 26日 六月 2024 17:50:59 | ||||
| --- | ||||
| # 静态库 | ||||
| - MDd | ||||
| 	- 动态链接 msvcrtd.dll | ||||
| - MD | ||||
| 	- 动态链接 msvcrt.dll | ||||
| - MTd | ||||
| 	- 静态链接 libcmtd.lib | ||||
| - MT | ||||
| MT 与 MD 的区别在于底层多线程库与c++标准库不同 | ||||
| 	- 静态链接 libcmt.lib | ||||
| MT 与 MD 的区别在于底层多线程库与c++标准库不同, 仅仅影响底层内存与多线程的调试 | ||||
| ``` | ||||
| dumpbin /directives myzlib.lib | ||||
| ``` | ||||
| 
 | ||||
| ## 动态库 | ||||
| 依赖静态库时,如只提供lib 文件与 pdb文件。生成的dll 依然不会包含lib的调试信息。需要手动添加 | ||||
| ## UE | ||||
| 默认所有模块都是MD模式 | ||||
| ## Xmake | ||||
| set_vs_runtime("MD") | ||||
| add_requires("sentry-native", {configs = {shared = true, debug = true, backend = "crashpad", vs_runtime="MD"}}) | ||||
| SENTRY_BUILD_STATIC | ||||
| ## 链接 | ||||
| - [Windows Visual Studio中静态库与动态库加载](https://www.cnblogs.com/lishanyang/p/17040100.html "发布于 2023-01-10 13:49") | ||||
| 
 | ||||
| 
 | ||||
| ``` | ||||
| #pragma region ouczbs | ||||
| #include <DbgHelp.h> | ||||
| #if _MSC_VER | ||||
| #define snprintf _snprintf | ||||
| #endif | ||||
| #pragma comment(lib, "dbghelp.lib") | ||||
| #define STACK_INFO_LEN 1024 | ||||
| void WriteCrashLog(const char* logContent) { | ||||
|   // 生成唯一文件名 | ||||
|   time_t now = std::time(nullptr); | ||||
|   char filename[256]; | ||||
|   std::strftime(filename, | ||||
|                 sizeof(filename), | ||||
|                 "D:\\ue_crash_%Y%m%d_%H%M%S.log", | ||||
|                 std::localtime(&now)); | ||||
| 
 | ||||
|   // 打开文件并写入 | ||||
|   FILE* file = fopen(filename, "w"); | ||||
|   if (file) { | ||||
|     fputs(logContent, file); | ||||
|     fclose(file); | ||||
|   } | ||||
| } | ||||
| void ShowTraceStack(char* szBriefInfo) { | ||||
|   static const int MAX_STACK_FRAMES = 12; | ||||
|   void* pStack[MAX_STACK_FRAMES]; | ||||
|   static char szStackInfo[STACK_INFO_LEN * MAX_STACK_FRAMES]; | ||||
|   static char szFrameInfo[STACK_INFO_LEN]; | ||||
| 
 | ||||
|   HANDLE process = GetCurrentProcess(); | ||||
|   SymInitialize(process, NULL, TRUE); | ||||
|   WORD frames = CaptureStackBackTrace(0, MAX_STACK_FRAMES, pStack, NULL); | ||||
|   strcpy(szStackInfo, szBriefInfo == NULL ? "stack traceback:\n" : szBriefInfo); | ||||
| 
 | ||||
|   for (WORD i = 0; i < frames; ++i) { | ||||
|     DWORD64 address = (DWORD64)(pStack[i]); | ||||
| 
 | ||||
|     DWORD64 displacementSym = 0; | ||||
|     char buffer[sizeof(SYMBOL_INFO) + MAX_SYM_NAME * sizeof(TCHAR)]; | ||||
|     PSYMBOL_INFO pSymbol = (PSYMBOL_INFO)buffer; | ||||
|     pSymbol->SizeOfStruct = sizeof(SYMBOL_INFO); | ||||
|     pSymbol->MaxNameLen = MAX_SYM_NAME; | ||||
| 
 | ||||
|     DWORD displacementLine = 0; | ||||
|     IMAGEHLP_LINE64 line; | ||||
|     line.SizeOfStruct = sizeof(IMAGEHLP_LINE64); | ||||
| 
 | ||||
|     if (SymFromAddr(process, address, &displacementSym, pSymbol) && | ||||
|         SymGetLineFromAddr64(process, address, &displacementLine, &line)) { | ||||
|       snprintf(szFrameInfo, | ||||
|                sizeof(szFrameInfo), | ||||
|                "\t%s() at %s:%d(0x%x)\n", | ||||
|                pSymbol->Name, | ||||
|                line.FileName, | ||||
|                line.LineNumber, | ||||
|                (unsigned int)pSymbol->Address); | ||||
|     } else { | ||||
|       snprintf( | ||||
|           szFrameInfo, sizeof(szFrameInfo), "\terror: %d\n", GetLastError()); | ||||
|     } | ||||
|     strcat(szStackInfo, szFrameInfo); | ||||
|   } | ||||
|   WriteCrashLog(szStackInfo); | ||||
|   printf("%s", szStackInfo);  // 输出到控制台,也可以打印到日志文件中 | ||||
| } | ||||
| 
 | ||||
| static int s_loop_flag = 1; | ||||
| LONG WINAPI UnhandledExceptionHandler(EXCEPTION_POINTERS* exception_pointers) { | ||||
| #if defined(ADDRESS_SANITIZER) | ||||
|   // In ASan builds, delegate to the ASan exception filter. | ||||
|   LONG status = __asan_unhandled_exception_filter(exception_pointers); | ||||
|   if (status != EXCEPTION_CONTINUE_SEARCH) | ||||
|     return status; | ||||
| #endif | ||||
|   ShowTraceStack("UnhandledExceptionHandler Traceback"); | ||||
|   fprintf(stderr, "sentry UnhandledExceptionHandler fprintf 1.1 \n"); | ||||
|   LOG(ERROR) << "sentry UnhandledExceptionHandler log 1.1 "; | ||||
|   s_loop_flag = 1; | ||||
|   while (s_loop_flag) { | ||||
|     if (s_loop_flag) { | ||||
|       s_loop_flag = s_loop_flag + 1; | ||||
|     } | ||||
|     if (!s_loop_flag) { | ||||
|       s_loop_flag = 1; | ||||
|     } | ||||
|   } | ||||
|   fprintf(stderr, "sentry UnhandledExceptionHandler fprintf 1.2 \n"); | ||||
|   LOG(ERROR) << "sentry UnhandledExceptionHandler log 1.2 "; | ||||
|   if (BlockUntilHandlerStartedOrFailed() == StartupState::kFailed) { | ||||
|     // If we know for certain that the handler has failed to start, then abort | ||||
|     // here, rather than trying to signal to a handler that will never arrive, | ||||
|     // and then sleeping unnecessarily. | ||||
|     LOG(ERROR) << "crash server failed to launch, self-terminating"; | ||||
|     SafeTerminateProcess(GetCurrentProcess(), kTerminationCodeCrashNoDump); | ||||
|     return EXCEPTION_CONTINUE_SEARCH; | ||||
|   } | ||||
| #pragma endregion | ||||
| 
 | ||||
| ``` | ||||
							
								
								
									
										2
									
								
								src/u/unreal/UE4 插件.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										2
									
								
								src/u/unreal/UE4 插件.md
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,2 @@ | ||||
| # 第三方插件 | ||||
| ## 第三方库 | ||||
							
								
								
									
										25
									
								
								src/u/unreal/UE4打包.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										25
									
								
								src/u/unreal/UE4打包.md
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,25 @@ | ||||
| # 环境 | ||||
| ## 安卓打包 | ||||
| ### UE4.27 | ||||
| - Java Sdk | ||||
| 	- 下载旧版JDK8 | ||||
| 	- https://www.oracle.com/java/technologies/javase/javase8-archive-downloads.html | ||||
| 	- 环境变量 | ||||
| 		- JAVA_HOME | ||||
| - Android Studio | ||||
| 	- SDK Platforms | ||||
| 		- API 32 | ||||
| 		- ANDROID 5.0 | ||||
| 	- SDK Tools | ||||
| 		- Android SDK Build-Tools 28.0.3 | ||||
| 		- NDK  21.4.7075529 | ||||
| 	- 环境变量 | ||||
| 		- ANDROID_SDK_HOME | ||||
| # 报错 | ||||
| 安卓空项目 和 EM项目打包后,运行初始化阶段就遇到断言宕机了 | ||||
| - [PackagingResults: Error: Failed to build UATTempProj.proj](https://forums.unrealengine.com/t/packagingresults-error-failed-to-build-uattempproj-proj/649915) | ||||
| VS Studio重编一下 AutomationTool program 即可 | ||||
| - No Google Play Store Key | ||||
| 安卓打包时勾选  禁用首次开始 更新时验证OBB | ||||
| ![[Pasted image 20250319132136.png]] | ||||
| 
 | ||||
							
								
								
									
										4
									
								
								src/y/yingxiong/GM.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										4
									
								
								src/y/yingxiong/GM.md
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,4 @@ | ||||
| gm skipregion 1 101401 1 | ||||
| gm skipregion 1 101701 1 | ||||
| 
 | ||||
| Ptr=0x000002326280d1d0, SharedRefs=2, WeakRefs=1, Object={Data=Num=5 Data_NumIndex=Empty Data_RealString=Num=3 } | ||||
							
								
								
									
										21
									
								
								src/y/yingxiong/入职文档.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										21
									
								
								src/y/yingxiong/入职文档.md
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,21 @@ | ||||
| # TAPD版本制度 | ||||
| ## 版本制度 | ||||
| ### 周版本 7天 | ||||
| - 周五:19:00锁当周任务单 | ||||
| - 周一:19:00验收OK | ||||
| - 周二:版本日,修BUG,QA发搞定可撤才可下班 | ||||
| ### CE版本 42天 | ||||
| - 第五周:美术截止 | ||||
| - 第六周:开发截止 | ||||
| ### PS | ||||
| - 任务单评估要规范,延期、BUG多会很麻烦 | ||||
| - 提交周期要规范,需慎重 | ||||
| ## 任务单 | ||||
| ### 需求单 | ||||
| - PM管理W排期 | ||||
| ### BUG单 | ||||
| - QA管理W排期,PM辅助 | ||||
| 待验收时组长催单,交由对应PM管理 | ||||
| ## PPJ制度 | ||||
| - 2个月后进入PPJ评测,需要请客 | ||||
| -  | ||||
							
								
								
									
										45
									
								
								src/y/yingxiong/分工合作.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										45
									
								
								src/y/yingxiong/分工合作.md
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,45 @@ | ||||
| # 项目分工 | ||||
| ## 战斗组 | ||||
| - 教学手册 | ||||
| - MOD玩法 | ||||
| - 战斗技能 | ||||
| - 战令活动 | ||||
| - 剧情对话 | ||||
| ## 关卡组 | ||||
| - 关卡设计 | ||||
| - 区域地图系统 | ||||
| - 小地图优化 | ||||
| 
 | ||||
| ## 怪物组 | ||||
| - 物理性能 | ||||
| - 购物联机 | ||||
| - 任务流程 | ||||
| - 缓存池联机 | ||||
| 
 | ||||
| ## 交互组 | ||||
| - 战斗HUD | ||||
| - 主页UI | ||||
| 
 | ||||
| ## 优化组 | ||||
| 看性能 | ||||
| Niagara优化 | ||||
| GBuffer优化 | ||||
| 打包优化 | ||||
| 日志优化 | ||||
| 
 | ||||
| ## 引擎组 | ||||
| - 地形优化 Deformation | ||||
| - SWERenderer IOS性能 | ||||
| - PSO缓存,剔除优化 | ||||
| - 植被剔除优化 | ||||
| ## 服务端 | ||||
| - 埋点 | ||||
| - 区域联机 | ||||
| - 属性同步 | ||||
| - 支付接口 | ||||
| - 战令系统 | ||||
| - 热更优化 | ||||
| - 日志系统 | ||||
| # 个人分工 | ||||
| - 安装工作环境,跑游戏流程 | ||||
| - 自研CrashReporter | ||||
							
								
								
									
										21
									
								
								src/y/yingxiong/宕机日志.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										21
									
								
								src/y/yingxiong/宕机日志.md
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,21 @@ | ||||
| ## 文档链接 | ||||
| CrashEye UE4收集崩溃日志  https://zhuanlan.zhihu.com/p/28013163 | ||||
| ## 异常 | ||||
| - 分类 | ||||
| 	- C++异常 | ||||
| 		- 底层实现是 SEH 结构化异常 | ||||
| - 捕获 | ||||
| 	- try ... catch ... | ||||
| 	- 应用未捕获的异常交由内核捕获 | ||||
| ## 信号处理器 | ||||
| 
 | ||||
| ## UE4异常 | ||||
| ### Windows 平台 | ||||
| - EnsureExceptionCode | ||||
| - AssertExceptionCode | ||||
| - GPUCrashExceptionCode | ||||
| - CrashCode | ||||
| ## crashpad | ||||
| ### CrashpadClient::StartHandler | ||||
| 
 | ||||
| ![[Pasted image 20250312161120.png]] | ||||
							
								
								
									
										49
									
								
								src/y/yingxiong/工作记录.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										49
									
								
								src/y/yingxiong/工作记录.md
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,49 @@ | ||||
| ## 2025/3月 | ||||
| 昨天: | ||||
| 阅读项目文档 | ||||
| 安装工作环境 | ||||
| 今天 | ||||
| 跑游戏,阅读代码 | ||||
| 
 | ||||
| 昨天: | ||||
| 跑游戏,阅读代码 | ||||
| 今天: | ||||
| 宕机日志上报 | ||||
| 
 | ||||
| 昨天: | ||||
| PC端宕机日志上报 | ||||
| 今天: | ||||
| 安卓宕机日志上报 | ||||
| Loading界面蓝图替换 | ||||
| 
 | ||||
| 昨天: | ||||
| 安卓宕机日志上报 | ||||
| 今天: | ||||
| 继续安卓宕机日志上报 | ||||
| Loading界面蓝图替换 | ||||
| 昨天 | ||||
| Loading界面蓝图替换 | ||||
| 今天 | ||||
| 继续安卓宕机日志上报 | ||||
| 
 | ||||
| 昨天 | ||||
| 安卓宕机日志上报 | ||||
| 今天 | ||||
| 继续 | ||||
| 
 | ||||
| 昨天 | ||||
| 安卓宕机日志上报 | ||||
| 今天 | ||||
| 宕机符号解析 | ||||
| 
 | ||||
| 昨天 | ||||
| 宕机符号解析 | ||||
| 今天 | ||||
| 宕机符号解析 | ||||
| 服务器环境搭建 | ||||
| ## 宕机日志上报 | ||||
| - 选择Sentry-Unreal | ||||
| ## Loading界面替换 | ||||
| 
 | ||||
| WidgetBlueprint'/Game/UI/UI_PC/Common/CommonChangeSceneBg_PC.CommonChangeSceneBg_PC' | ||||
| 
 | ||||
							
								
								
									
										52
									
								
								src/y/yingxiong/目标设定.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										52
									
								
								src/y/yingxiong/目标设定.md
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,52 @@ | ||||
| ## 上半年目标 | ||||
| 4月2号之前填写 | ||||
| 工作内容,目标指标 | ||||
| 需要和上级沟通,达成一致后推进 | ||||
| 
 | ||||
| 我写了一版目标设定,格式内容这样写可以吗 | ||||
| ## 多端宕机日志基础体系建设 | ||||
| - 主要职责 | ||||
| 	- 多端宕机日志标准化采集(PC/安卓) | ||||
| 	- 配置免费开源日志监控方案 | ||||
| - 具体工作内容 | ||||
| 	- CrashSight 收费,寻找新的免费好用的解决方案 | ||||
| 	- 多端平台接入Sentry,收集宕机日志 | ||||
| 	- 解析宕机堆栈,建立宕机问题闭环处理流程 | ||||
| - 衡量标准 | ||||
| 	- 崩溃采集率> 95% | ||||
| 	- 日志信息完善,复现简单 | ||||
| 	- 至少修复一次高频崩溃问题 | ||||
| ## 性能与内存优化 | ||||
| - 主要职责 | ||||
| 	- 性能数据采集和分析,解决热点问题 | ||||
| - 具体工作内容 | ||||
| 	- PC 端使用 Unreal Frontend 查看帧率/内存曲线 | ||||
| 	- 安卓端用 Profile 记录帧率波动,重点关注界面加载|战斗场景 | ||||
| 	- 分析并解决内存、帧率热点问题 | ||||
| - 衡量标准 | ||||
| 	- 识别明显卡顿点 | ||||
| 	- 记录解决内存问题 | ||||
| 
 | ||||
| ## 策划系统需求 | ||||
| - 主要职责 | ||||
| 	- 按时按量完成策划需求 | ||||
| - 具体工作内容 | ||||
| 	- TAPD接单时与策划沟通明确需求,按时按量完成任务 | ||||
| 	- 提交代码前自测,尽量减少BUG | ||||
| - 衡量标准 | ||||
| 	- 按时按量交付 | ||||
| 	- 代码质量达标 | ||||
| 
 | ||||
| 
 | ||||
| ## 辅导计划 | ||||
| - 第一阶段 | ||||
| 	- 阅读飞书文档,包括行政规定、技术文档、TAPD等 | ||||
| 	- 配置开发环境,项目辅助工具 | ||||
| 	- 阅读熟悉项目代码,命名风格 | ||||
| 	- 玩游戏Warframe、二重螺旋,熟悉游戏功能 | ||||
| - 第二阶段 | ||||
| 	- 开始接手相关需求,重点阅读对应系统代码 | ||||
| 	- 开始熟悉工作流程,注重代码规范细节 | ||||
| - 第三阶段 | ||||
| 	- 过渡结束,接入正常工作节奏 | ||||
| 	- 按照规章流程接单、实现、测试等 | ||||
							
								
								
									
										49
									
								
								src/y/yingxiong/项目环境.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										49
									
								
								src/y/yingxiong/项目环境.md
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,49 @@ | ||||
| # UE环境 | ||||
| ### dll缺失 | ||||
| 安装 DirectX Repair.exe | ||||
| 
 | ||||
| ### 无法生成VS项目 | ||||
| 项目.uproject 文件 未与引擎关联,无法通过 Generate Visual Studio project files 生成对应VS项目。 | ||||
| - 找到 Engine/Binaries/Win64/UnrealVersionSelector.exe 文件 | ||||
| - 通过管理员运行 UnrealVersionSelector.exe ,注册到 Window 系统中 | ||||
| - 选择 UnrealVersionSelector.exe 打开.uproject 文件,可以看到对应的 Generate Visual Studio project files | ||||
| ###  __cplusplus 宏定义缺失 | ||||
| UE error C4668: 没有将“__cplusplus”定义为预处理器宏,用“0”替换“#if/#elif” | ||||
| - 原VS Studio是引擎自动下载的 | ||||
| - 暂时更换VS Studio 版本为2022 | ||||
| ### 编译模式 | ||||
| 默认选择 Development Editor | ||||
| # 游戏系统 | ||||
| ## UI框架 | ||||
| Tips: 监听 UIManager对象的AddLoadedUI | ||||
| - 数据 | ||||
| 	- SystemUI.lua | ||||
| 		- 包含所有系统UI相关配置 | ||||
| 	- SystemUI.xlsx | ||||
| 		- UI注释表 | ||||
| - 常用接口 | ||||
| 	- BP_UIManagerComponent_C.lua | ||||
| 		- LoadUINew / LoadUI | ||||
| 			- 加载UI | ||||
| 		- UnLoadUINew / UnLoadUI | ||||
| 			- 卸载UI | ||||
| - ShowLoadingUI | ||||
| 	- loading界面 | ||||
| - InnerChangeRegionByRegionId | ||||
| 	- 区域跳转 | ||||
| ## 数据表 | ||||
| - DataMgr | ||||
| ## 宕机日志 | ||||
| 
 | ||||
| ## GM指令 | ||||
| ## 网络协议 | ||||
| ## 战斗系统 | ||||
| 
 | ||||
| ## 红点系统 | ||||
| 
 | ||||
| 
 | ||||
| Loading界面蓝图替换 | ||||
| 自研CrashReporter | ||||
| 
 | ||||
| 请假 | ||||
| #请假 调休 3.18 上午4h @程序/刘英卓 @程序/揭忠/json @系统线PM/王婷 @庄嘉伟/伟哥 | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user