1 (edited by GreYFoX 2011-12-27 00:01:56)

Topic: [Development] How to develop for Teeworlds using Eclipse on Windows

NOTE: This tutorial assumes you are already developing either recently or for sometime for Teeworlds some other way and want to try a better way, so you will have the compiler installed and have compiled Teeworlds at least once on that machine!

Part 1: Download

1.    

Eclipse: - http://eclipse.org/downloads/

2.    Java JRE: - http://www.java.com/en/download/index.jsp
    • Note: if you install JRE x64 bit and eclipse crashes a lot then you can install the x86 JRE
3.    Bam: - https://github.com/matricks/bam/zipball/master
    • Extract bam them add those 2 files in the same directory:
    • https://raw.github.com/GreYFoX/bam/custom/bam.bat
    • https://raw.github.com/GreYFoX/bam/cust … nstall.bat
4.    Tortoise Git 1.7.x.x: - http://code.google.com/p/tortoisegit/downloads/list <-- optional (for Git noobs and GUI lovers)

5.    Git-1.7.X-previewYYYYMMDD.exe: - http://code.google.com/p/msysgit/downloads/list <-- optional (for people who want to use Git)
Note: I Didn't surround this part with a code tag like the others so u can click the links

Part 2: Installation

1)    
Install JRE, close your eyes and hit next next next finish
2)    
Install Git, while in installation you need to choose the following options: 
(leave everything else as is - this is a recommendation not an order)

    • Git Bash Here

    • Git GUI Here

    • Run Git from Windows Command Prompt

    • Use Opens’
    • Checkout windows-style, commit Unix-style line endings

3)    Install TortoiseGit, you usual super next next next, finish

4)    Build and install bam

    • make_win32_msvc.bat

    • win32_install.bat

5)    Extract eclipse anywhere you like

Part 3: Configuration

1)    
Open eclipse

2)    Choose or create a workspace
3)    
Make it default so it never asks again (and if it ever asks again later then you have more than 1 eclipse running)

4)    Help > Install New Software > Work With: "-- All Available Sites --"
    • Choose Github from collaboration
    • Install it
    • Restart
5)    Clone/Download/Copy a Teeworlds project folder called Teeworlds into the workspace.
    • Note: so it should look like: workspace path\Teeworlds\src…
6)    File > new > C++ Project
    • Choose the name Teeworlds hit finish
7)    Right click Teeworlds (the project root) then choose properties or from the menu project choose properties
    a)    C/C++ General >Paths and Symbols >Add
    b)    Choose add to all configuration
    c)    Choose add to all languages
    d)    Click workspace
    e)    Choose /Teeworlds/other/freetype/include
    f)    Repeat a to d for path /src
    g)    Repeat a to d for path /Teeworlds/other/mysql/include (for DDRace i.e.)
    h)    Repeat a to d for path /Teeworlds/other/sdl/include
    i)    Repeat a to c then click filesystem
    j)    Path C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include (or what ever version of M$ VC u have path to include)
    k)    Go to Source Location and click add
    l)    Choose src
    m)    Delete /Teeworlds
    n)    Go to C/C++ Build
    o)    Choose all configurations (at the top)
    p)    Uncheck use default build command
    q)    Type in "bam.bat " instead of "make "
    r)    Uncheck generate make files auto...
    s)    Choose debug (at the top)
    t)    Change ${workspace_loc:/Teeworlds/Debug} to ${workspace_loc:/Teeworlds}
    u)    Choose release and repeat t
    v)    Choose debug and go t behavior
    w)    In build (incremental build) put: server_debug client_debug
    x)    In clean: -c server_debug client_debug
    y)    Go to release
    z)    Do w and x with _release instead of _debug
        • NOTE: now you have learned your abcdefghijklmnopqrstuvwxyz.
8)    Right click Teeworlds (project) > Team > Share Project > Git > check Use or Create.... > click finish (only if you have a Git repo there)


Enjoy your auto complete and fully functional IDE
Keep following my next Tutorials to know how to debug using gdb

if you are looking for support for DDRace, please go to http://DDRace.info.

2 (edited by Malachite 2012-08-25 12:32:52)

Re: [Development] How to develop for Teeworlds using Eclipse on Windows

Why install an extra Git client if Eclipse has a nice plugin for this?
http://www.eclipse.org/egit/

You can even view your GitHub issues inside Eclipse:
http://www.eclipse.org/mylyn/
http://marketplace.eclipse.org/content/ … -connector


(Aptana Studio has BTW an own Git plugin which is a very nice extension to Egit because it provides all the features which Egit does not have (like project diff, repo status in the project explorer etc.))

3

Re: [Development] How to develop for Teeworlds using Eclipse on Windows

How to develop for Teeworlds using Vi on Linux:

1) vi ./teeworlds/*
2)???????
3)PROFIT!

As many other things on planet, this one can be solved with Vi.