Skip to content

Library & toolchain for Neo Geo CD develop. with C language

Notifications You must be signed in to change notification settings

ResistanceVault/neocore

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Neocore

Platform License: MIT

Neocore is a library and toolchain for developing on Neo Geo CD.
It provides functions over Neo Dev Kit and DATlib 0.2, and includes tools and code that can help with projects on this platform.

  • High abstraction level for Neo Geo CD development
  • Compatible with Windows 10 and Windows 11

Game, demo, code learning using Neocore

Init

git clone https://github.com/David-Vandensteen/neocore.git

Build and run the hello sample

cd .\neocore\samples\hello
.\mak.bat run:mame

Mak rules

Warning: The mak script overrides the path environment variable during compilation.
If you encounter any problems after using it, simply close and restart a new command terminal.

  • Clean the builded resources
.\mak.bat clean
  • Build sprites
.\mak.bat sprite
  • Build the program
.\mak.bat
  • Build the ISO file
.\mak.bat iso
  • Run with Raine
.\mak.bat run:raine
  • Run with Mame
.\mak.bat run:mame
  • Display version information
.\mak.bat --version

Create a project

  • Go to the folder where you've cloned this Neocore repository (replace <neocore> with your path in the following command)
cd <neocore>\bootstrap\scripts\project
  • Replace myGame and c:\temp\myGame with your data in the following command
.\create.bat -name myGame -projectPath c:\temp\myGame
  • Go to the src folder project (replace c:\temp\myGame\src with your path in the following command)
cd c:\temp\myGame\src
  • Compile and run it
.\mak.bat run:mame

Upgrade an existing project

It's recommended to back up your project folder before starting.
This process does not upgrade your code, XML project definition, or assets and you must handle any breaking changes yourself.
The files mak.bat and mak.ps1 will be overwritten.
Neocore Toolchain will be replaced.
Neocore Lib C will be replaced.

  • Remove the build folder in your project (replace c:\temp\myGame\build with your path in the following command)
rd /S /Q c:\temp\myGame\build
  • Go to the folder where you've cloned this Neocore repository (replace <neocore> with your path in the following command)
cd <neocore>\bootstrap\scripts\project
  • For upgrading your project, replace c:\temp\myGame\src and c:\temp\myGame\neocore with your data in the following command
.\upgrade.bat -projectSrcPath c:\temp\myGame\src -projectNeocorePath c:\temp\myGame\neocore

Release a project

  • Go to your src folder project (replace c:\temp\myGame\src with your path in the following command)
cd c:\temp\myGame\src
  • ISO
.\mak.bat dist:iso
  • MAME
.\mak.bat dist:mame
  • EXE (create a Windows standalone executable with the game project and Mame emulator embedded)
.\mak.bat dist:exe

Documentation of Neocore C lib

Note

Please note that the library is under development and the author is not responsible for any software damage.
This project is mainly tested on Raine and MAME emulators.

There is no guarantee or obligation from the author that anything will work on the real Neo-Geo hardware.

To test and improve compatibility with the hardware, I am searching for a Neo-Geo CD with an SD loader and HDMI capabilities.
You can contribute to this effort with a donation if you want.

Make a Paypal donation to help Neocore project

Here are other ways to contribute:

  • If you own a Neo-Geo CD, you can test the examples and open or confirm issues on real hardware.
  • If you are a developer, you can create tutorials or example code.

Any help is welcome.

DATlib assets

For making graphics, see the DATlib ref available here: http://azertyvortex.free.fr/download/DATlib-LibraryReference.pdf

Neocore embed the content of chardata.xml in project.xml

<project>
  <gfx>
    <DAT>
      <chardata>
      </chardata>
    </DAT>
  </gfx>
</project>

For launching the DATlib Framer application:

.\mak.bat framer

For launching the DATlib Animator application:

.\mak.bat animator

Pull or checkout another branches

BE CAREFUL : You need to remove build folder .\neocore\build for supress cache files before compiling a project

Hot reload

  • Go to the folder where you've cloned this Neocore repository (replace <neocore> with your path in the following command)
cd <neocore>\samples\hello
.\mak.bat serve

Wait for the emulator to run and edit main.c.
Now, remove nc_log_info("DAVID VANDENSTEEN"); line.
Save the file.

The hot-reload process will rebuild & run your project automaticaly.

Some problems currently:

  • The process is not a real watcher (the rebuild is triggered only if the folder size change)
  • When you break this process, path is not restored in the current terminal (close & reopen a new terminal)

Compiling the lib (necessary if you develop Neocore lib)

  • Go to the folder where you've cloned this Neocore repository (replace <neocore> with your path in the following command)
cd <neocore>\src-lib
.\build-neocore.bat -gccPath ..\build\gcc\gcc-2.95.2 -includePath ..\build\include -libraryPath ..\build\lib

This script override path environment variable during the compilation.
its avoid collisions with other bin, sdk, gcc...
If sdk was not found, build a sample (with mak script) to initialize cache (sdk will install in build folder).

Dependencies

  • NeoDev
  • DATlib
  • DATimage
  • NGFX SoundBuilder
  • Raine
  • Mame
  • CHDMAN
  • Doxygen
  • MSYS2
  • Mkisofs
  • GCC
  • mpg123
  • ffmpeg
  • NSIS

License

Neocore is licensed under the MIT license.
Copyright 2019 by David Vandensteen.
Some graphics by Grass.

About

Library & toolchain for Neo Geo CD develop. with C language

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • PowerShell 47.1%
  • C 37.9%
  • Assembly 8.3%
  • Batchfile 3.8%
  • Makefile 1.6%
  • Shell 0.9%
  • NSIS 0.4%