"Chibi" learning notes (1)

zhaozj2021-02-08  220

I have long heard that "Chibi" game is a pioneer in domestic games. Later, I heard that sales is not very good, just selling the source code, which is the "G file" that the industry is often said. I have a hard work, downloaded the source code and the standard version of the game execution file on the Internet.

Analysis of cbmain.cpp, the general situation is as follows:

Bool mmxcpuid () is mainly to monitor whether the CPU supports MMX functionality.

Bool main_testinstance () Detection If there is already an instance of this game is running, the new instance is no longer re-enabled.

Bool main_testcd () Detection If it is a deluxe version, you need to insert a CD.

Bool doinit () Game initialization.

Bool main_initothers () Game initialization.

INT Pascal WinMain () is the game main program entry.

Where the main window initialization function DD_INITWINDOW () is defined in ddapi.cpp.

GAME_GETSRCPATH () is defined in cbgame.cpp in cbgame.cpp, and the content of Wayahead.dat file is encrypted here.

There is such a code in the main program, which should be detected to support MMX, showing the MMX icon.

IF (IntelSplashinit () == True)

{

Intelsplash ();

}

There are still a lot of places that don't understand, I hope to have the same way to learn together, analyze together, make progress together.

转载请注明原文地址:https://www.9cbs.com/read-2619.html

New Post(0)