啃传奇服务器端的源码

传奇源码分析-服务器端(LoginSvr服务器分析)    LoginSvr服务器g_gcSock Local    5500端口1.首先从LoginSvr.cpp  WinMain分析:   1) CheckAvailableIOCP : 检查是不是NT,2000的系统(IOCP)   2) InitInstance: 初始化界面,加载WSAStartup       GetDBManager()->Init( Inse 阅读详情

最近开启的新项目是使用python写一个传奇2的模拟器,所以先分析一下原来的程序,貌似很困难,反正闲着也是闲着,无聊还是无聊

难过

不用解释了,不过对我这种没有windows编程经验的来说很难啃
// LoginGate.cpp : Defines the entry point for the application.
//

#include “stdafx.h”

// **************************************************************************************

BOOL    InitApplication(HANDLE hInstance);
BOOL    InitInstance(HANDLE hInstance, int nCmdShow);
LPARAM    APIENTRY MainWndProc(HWND hWnd, UINT nMsg, WPARAM wParam, LPARAM lParam);

BOOL    jRegSetKey(LPCTSTR pSubKeyName, LPCTSTR pValueName, DWORD dwFlags, LPBYTEpValue, DWORD nValueSize);
BOOL    jRegGetKey(LPCTSTR pSubKeyName, LPCTSTR pValueName, LPBYTE pValue);

BOOL    CALLBACK ConfigDlgFunc(HWND hWndDlg, UINT uMsg, WPARAM wParam, LPARAMlParam);

// **************************************************************************************
//
//            Global Variables Definition
//
// **************************************************************************************

HINSTANCE        g_hInst = NULL;                // Application instance
HWND            g_hMainWnd = NULL;            // Main window handle
HWND            g_hLogMsgWnd = NULL;
HWND            g_hToolBar = NULL;
HWND            g_hStatusBar = NULL;

BOOL            g_fTerminated = FALSE;

static WSADATA    g_wsd;

TBBUTTON tbButtons[] =
{
{ 0, IDM_STARTSERVICE,    TBSTATE_ENABLED,    TBSTYLE_BUTTON, 0L, 0},
{ 1, IDM_STOPSERVICE,    TBSTATE_ENABLED,&nb

传奇2源码深度解析:从Delphi客户端到服务器端的完整拆解 现代网络游戏开发中,后端架构与客户端交互的核心概念,如服务器权威、AOI视野管理、坐标同步与封包协议,其实早在二十年前的经典MMORPG中就已形成雏形。对于想深入理解游戏底层原理的开发者来说,阅读老牌开源项目往往比学习庞大商业引擎更高效。本文从游戏服务器的基本进程划分、数据访问层抽象、二进制封包设计等通用技术切入,结合传奇2(LegendOfMir3_Src)这套由Delphi编写的完整客户端与服务端源码,详细剖析瓦片地图加载、序列帧动画、客户端乐观预测、服务端坐标校验、多进程协作等关键模块。通过梳理项目结 阅读详情

相关推荐

传奇游戏服务端与客户端C++源码解析实战

传奇游戏作为早期的多人在线角色扮演游戏(MMORPG)之一,拥有复杂而精巧的源码结构。其设计必须支持大量并发玩家、角色数据同步、网络通信等多方面的技术挑战。本章我们从源码层面剖析其结构,深入理解游戏服务器、客户端和网络通信的基本构成。C++是一种静态类型、编译式、通用的编程语言。它支持多范式编程,包括过程化、面向对象和泛型编程。C++的主要特性可以概括为:高效的性能:C++直接与内存和硬件打交道,从而允许开发者优化性能至极致。

weixin_31641077的博客 1005

传奇游戏公司网站源码构建完整指南

在当今互联网时代,游戏公司网站不仅是展示游戏产品的窗口,也是与玩家互动的重要平台。一个优秀的游戏公司网站需要具备吸引用户的界面设计、流畅的用户体验以及稳定安全的后端支撑。本章节将对游戏公司网站源码进行一个总体概述,包括其基本组成部分、功能特点以及如何为游戏公司提供技术支持和服务。

weixin_35757191的博客 443

Mir2源码完整版(服务端+客户端)

Mir2源码完整版 Mir2源码完整版 Mir2源码完整版 Mir2源码完整版

盛大网络05年8月泄露版绝对原版

盛大网络05年8月泄露版服务端,绝对原版,引擎自己配置,其他的都是官方设置!

早期彩虹引擎全套_传奇世界_传奇引擎_传奇服务端_早期彩虹引擎_

传奇世界早期彩虹源码包含 客户端 服务端

LegendOfMir3_Src:传奇2客户端和服务器端

LegendOfMir3_Src 传奇2客户端和服务器端源码 网上下载的原始码,很有参考价值是否能编译不知道,但是验证过封包解析部分的逻辑是对的

TMS320F28377D/F28379D CAN通信避坑指南:从寄存器配置到中断处理的完整流程

本文详细解析了TMS320F28377D/F28379D在CAN通信开发中的关键技术与避坑指南,涵盖时钟配置、寄存器初始化、中断处理等完整流程。针对工业控制和汽车电子应用,提供了实用的优化技巧和错误诊断方法,帮助开发者高效实现稳定可靠的CAN通信。

weixin_30954265的博客 492

在银河麒麟V10上部署Atlas 300i Duo:从固件到驱动的一站式踩坑笔记

日期:2025-09-09关键词:鲲鹏920、Atlas 300i Duo、银河麒麟V10、NPU、驱动、固件。

weixin_41544125的博客 2813

逆向解析手淘x-sign签名算法:从抓包到API调用的完整实践

本文详细解析了手淘x-sign签名算法的逆向过程,从抓包工具选择到API调用实践,提供了完整的解决方案。通过分析签名参数组成和生成机制,帮助开发者理解并实现淘宝接口的合法调用,同时强调了安全与合规的重要性。

weixin_29323273的博客 606

基因的富集分析

通过RNA_seq差异表达分析等获得一组基因,想要进一步了解这些基因可能参与哪些生物学过程,具有哪些功能,一般就会用到基因的富集分析了。现在小麦基因注释信息已经可以获得,目前来看包括两套。一个是TGACv1,另一个就是IWGSC1.0。需要用到一个叫“clusterProfiler”的R包。下面用到的数据集来自TGACv1。1、安装source("https://bioconductor.org/b

xxxxx 1万+

【软件系统架构】系列六:系统工程

系统工程是一种跨学科方法论,用于分析、设计、集成和管理复杂系统的全生命周期。其核心特点包括系统性思维、全周期管理、跨学科协作和需求导向。主流采用V模型生命周期,涵盖需求分析、系统设计、实现、测试验证及运维退役等阶段。核心工作方法包括需求工程、系统建模、接口设计、风险管理等。系统工程与项目管理协同,分别侧重技术实现和进度资源管理。应用领域覆盖航天军工、智能制造、智慧城市等。未来将向AI融合、数字孪生、模型驱动工程等方向发展,为复杂系统开发提供系统化协作范式。

moton2017的博客 2257

时间序列预测 | 决策树时间序列预测建模,单步、多步(Python)

时间序列预测 | 决策树时间序列预测建模,单步、多步(Python)

天天酷科研的博客 745

DeerFlow 系列教程 第十一篇 | Sandbox 沙箱与 Memory 记忆——安全执行与持久认知

用户请求│▼Lead Agent├── 系统提示词组装│ ├── <memory> 段 ← Memory 系统注入用户记忆│ ├── <skill_system> 段│ └── <subagent_system> 段│├── 工具调用│ ├── read_file ├── Sandbox 系统提供隔离执行│ ├── write_file├── 路径虚拟化 + 安全验证│└── 对话结束│▼│├── 过滤消息(去除工具调用中间步骤)├── 检测纠正/强化信号。

weixin_43674738的博客 161

图像拼接(Image Stitching)

图像拼接(Image Stitching):是一项计算机视觉技术,它将多张重叠的图像合并为一张更大、无缝的全景图或广角视图。该技术广泛应用于全景摄影、地图制作、医学影像处理、计算机视觉及增强现实(AR)等领域。

📷 图像处理践行者 | 传统算法 · 深度学习 · 多模态 | 分享实战经验与技术洞见,探索从像素到智能的无限可能。 2505

Probability and Statistics - 4th edition

Probability and Statistics - 4th edition

深度学习工具包 DeepLearningToolbox

深度学习工具包Deprecation notice.-----This toolbox is outdated and no longer maintained.There are much better tools available for deep learning than this toolbox, e.g. [Theano](http://deeplearning.net/software/theano/), [torch](http://torch.ch/) or [tensorflow](http://www.tensorflow.org/)I would suggest you use one of the tools mentioned above rather than use this toolbox.Best, Rasmus.DeepLearnToolbox================A Matlab toolbox for Deep Learning.Deep Learning is a new subfield of machine learning that focuses on learning deep hierarchical models of data.It is inspired by the human brain's apparent deep (layered, hierarchical) architecture.A good overview of the theory of Deep Learning theory is[Learning Deep Architectures for AI](http://www.iro.umontreal.ca/~bengioy/papers/ftml_book.pdf)For a more informal introduction, see the following videos by Geoffrey Hinton and Andrew Ng.* [The Next Generation of Neural Networks](http://www.youtube.com/watch?v=AyzOUbkUf3M) (Hinton, 2007)* [Recent Developments in Deep Learning](http://www.youtube.com/watch?v=VdIURAu1-aU) (Hinton, 2010)* [Unsupervised Feature Learning and Deep Learning](http://www.youtube.com/watch?v=ZmNOAtZIgIk) (Ng, 2011)If you use this toolbox in your research please cite [Prediction as a candidate for learning deep hierarchical models of data](http://www2.imm.dtu.dk/pubdb/views/publication_details.php?id=6284)```@MASTERSTHESIS\{IMM2012-06284, author = "R. B. Palm", title = "Prediction as a candidate for learning deep hierarchical models of data", year = "2012",}```Contact: rasmusbergpalm at gmail dot comDirectories included in the toolbox-----------------------------------`NN/` - A library for Feedforward Backpropagation Neural Networks`CNN/` - A library for Convolutional Neural Networks`DBN/` - A library for Deep Belief Networks`SAE/` - A library for Stacked Auto-Encoders`CAE/` - A library for Convolutional Auto-Encoders`util/` - Utility functions used by the libraries`data/` - Data used by the examples`tests/` - unit tests to verify toolbox is workingFor references on each library check REFS.mdSetup-----1. Download.2. addpath(genpath('DeepLearnToolbox'));Example: Deep Belief Network---------------------```matlabfunction test_example_DBNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit RBM and visualize its weightsrand('state',0)dbn.sizes = [100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);figure; visualize(dbn.rbm{1}.W'); % Visualize the RBM weights%% ex2 train a 100-100 hidden unit DBN and use its weights to initialize a NNrand('state',0)%train dbndbn.sizes = [100 100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);%unfold dbn to nnnn = dbnunfoldtonn(dbn, 10);nn.activation_function = 'sigm';%train nnopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.10, 'Too big error');```Example: Stacked Auto-Encoders---------------------```matlabfunction test_example_SAEload mnist_uint8;train_x = double(train_x)/255;test_x = double(test_x)/255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit SDAE and use it to initialize a FFNN% Setup and train a stacked denoising autoencoder (SDAE)rand('state',0)sae = saesetup([784 100]);sae.ae{1}.activation_function = 'sigm';sae.ae{1}.learningRate = 1;sae.ae{1}.inputZeroMaskedFraction = 0.5;opts.numepochs = 1;opts.batchsize = 100;sae = saetrain(sae, train_x, opts);visualize(sae.ae{1}.W{1}(:,2:end)')% Use the SDAE to initialize a FFNNnn = nnsetup([784 100 10]);nn.activation_function = 'sigm';nn.learningRate = 1;nn.W{1} = sae.ae{1}.W{1};% Train the FFNNopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.16, 'Too big error');```Example: Convolutional Neural Nets---------------------```matlabfunction test_example_CNNload mnist_uint8;train_x = double(reshape(train_x',28,28,60000))/255;test_x = double(reshape(test_x',28,28,10000))/255;train_y = double(train_y');test_y = double(test_y');%% ex1 Train a 6c-2s-12c-2s Convolutional neural network %will run 1 epoch in about 200 second and get around 11% error. %With 100 epochs you'll get around 1.2% errorrand('state',0)cnn.layers = { struct('type', 'i') %input layer struct('type', 'c', 'outputmaps', 6, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %sub sampling layer struct('type', 'c', 'outputmaps', 12, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %subsampling layer};cnn = cnnsetup(cnn, train_x, train_y);opts.alpha = 1;opts.batchsize = 50;opts.numepochs = 1;cnn = cnntrain(cnn, train_x, train_y, opts);[er, bad] = cnntest(cnn, test_x, test_y);%plot mean squared errorfigure; plot(cnn.rL);assert(er<0.12, 'Too big error');```Example: Neural Networks---------------------```matlabfunction test_example_NNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);% normalize[train_x, mu, sigma] = zscore(train_x);test_x = normalize(test_x, mu, sigma);%% ex1 vanilla neural netrand('state',0)nn = nnsetup([784 100 10]);opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samples[nn, L] = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.08, 'Too big error');%% ex2 neural net with L2 weight decayrand('state',0)nn = nnsetup([784 100 10]);nn.weightPenaltyL2 = 1e-4; % L2 weight decayopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex3 neural net with dropoutrand('state',0)nn = nnsetup([784 100 10]);nn.dropoutFraction = 0.5; % Dropout fraction opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex4 neural net with sigmoid activation functionrand('state',0)nn = nnsetup([784 100 10]);nn.activation_function = 'sigm'; % Sigmoid activation functionnn.learningRate = 1; % Sigm require a lower learning rateopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex5 plotting functionalityrand('state',0)nn = nnsetup([784 20 10]);opts.numepochs = 5; % Number of full sweeps through datann.output = 'softmax'; % use softmax outputopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex6 neural net with sigmoid activation and plotting of validation and training error% split training data into training and validation datavx = train_x(1:10000,:);tx = train_x(10001:end,:);vy = train_y(1:10000,:);ty = train_y(10001:end,:);rand('state',0)nn = nnsetup([784 20 10]); nn.output = 'softmax'; % use softmax outputopts.numepochs = 5; % Number of full sweeps through dataopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, tx, ty, opts, vx, vy); % nntrain takes validation set as last two arguments (optionally)[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');```[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/rasmusbergpalm/deeplearntoolbox/trend.png)](https://bitdeli.com/free "Bitdeli Badge")

霍尼韦尔SoftMaster使用说明

霍尼韦尔SoftMaster使用说明

VB摄像头监控

该VB模块可对摄像头捕获的画面进行录像等,可在创建的窗口进行控制

上一篇: 使用python和蒙特卡洛方法算π
下一篇: 10个迷惑新手的Cocoa,Objective-c开发难点和问题
程序员迈克
博客等级 码龄16年 36粉丝 71原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值