This site has been archived and made available for preservation purposes. No edits can be made.

Results 1 to 2 of 2

Thread: Tutorial: Compile vaultscript with CodeBlocks on Windows

  1. #1

    Exclamation Tutorial: Compile vaultscript with CodeBlocks on Windows

    Download and install required software
    Download and install Code::Blocks from https://www.codeblocks.org/downloads
    Download and install latest MinGW from https://sourceforge.net/projects/ming...d?source=files

    Setup Code::Blocks to work with new MinGW
    Launch Code::Blocks

    Go to Settings -> Compiler and debugger...
    Under Toolchain executables change Compiler's installation directory to where you installed MinGW (Default C:\MinGW\)

    Create a project for vaultscript
    Create a new project (File -> New -> Project...)
    Choose Dynamic Link Library as the project type.
    Choose a suitable location for the project.
    Copy vaultscript.cpp and vaultscript.h files to where your project is.
    Remove main.cpp and main.h from the project and delete the files. (Optional but I recommend this)

    Set compiler and linker options
    Right click your project name in the Management view and choose Build options...
    Select the project name from the menu on the left. That way you don't have to add the options for both Debug and Release separately.
    Under Compiler settings -> Other options add the following line:
    -std=gnu++11

    Under Linker settings / Other linker options add the following lines:
    -static-libgcc
    -static-libstdc++

    Remove user32 from Linker settings / Link libraries (You'll find this in Debug/Release)

    Set project build path
    Right click your project name in the Management view and choose Properties...
    Under Build targets set Output filename: to where your vaultmp server's executable is located.
    Set this for both Debug and Release.

    Finishing touches
    Change build target to Release (It's on the toolbar)
    Compile (gear icon)
    Add vaultscript.dll into the vaultserver.ini's scripts
    Launch server and all should work just fine.

    Happy scripting!
    Last edited by zamp; 12-15-2012 at 05:58 AM.

  2. #2
    Heads up, MinGW only offers support on versions higher than 1.7.0 for C++11.


    I just come here to view whether there has been any progress or not, and review the wonderful progress that Recycler and the development team has made.
    My sincere thanks goes to them and to others who value my contributions the community, not to mention the ones that solely contribute.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •