Lamecraft - Community
Dont have an account? You can register for free!

Join the forum, it's quick and easy

Lamecraft - Community
Dont have an account? You can register for free!
Lamecraft - Community
Would you like to react to this message? Create an account in a few clicks or log in to continue.

How to mod Lamecraft source? [Tutorial]

Go down

How to mod Lamecraft source? [Tutorial] Empty How to mod Lamecraft source? [Tutorial]

Post  Rainy Thu Nov 03, 2011 2:03 am

How to mod Lamecraft source?
Tutorial by 10$man


Intro

Hello fellow LameCrafters . This is a tutorial on modding the source code of lamecraft to better suite your playing style. (speed,camera sensitivity,etc.) I am assuming by following this tutorial you already know basic knowledge of programming, or understand fundamentals.

Aquiring the source.
I am understanding that some people do not understand SVN. This is not a problem. To download from an SVN Repository you can follow these steps:
1.
You first must download an SVN client. I will use SVN Tortoise.
2.
once you have downloaded and installed, you must go and make a new folder. lets say:
LameCraft SourceCodes
3.
Now you must right click that folder. when you right click you should now see new options. they will say:
SVN checkout
TortoiseSVN
Go ahead and put your cursor over TortoiseSVN. A drop down menu will apear.
now click export on the drop down menu.
a little window will pop up.
4.
In this window you will see a box titled URL of repository. in this box copy and paste this in:

Code:
http://lamecraft.googlecode.com/svn/trunk
5.
Now you click Ok at the bottom of the window.
You should see the download start.
when it is finished Congrats you have aquired the source!

How to edit the source.
Now that you have the source you probably want to do something with it
you can download many different editors dev-c++, Code::Blocks, Visual studio,etc. also you could use notepad.

I recomend Code::Blocks.

go into the folder you download source to.
open the folder called Lamecraft.
You now probably see many files with the extensions .h and .cpp. These are C/C++ source files.
The one we are going to edit in this tutorial is:
StatePlay.cpp

Ok once you have this file open you should see much code. this code might or might not make sense to you.
This is ok

Go ahead and scroll down untill you see:
Code:

GRAVITY = -9.8f;
    JUMPVELOCITY = 4.0f;
    CLIMBVELOCITY = 2.5f;
It isn't far down on the source.

Ok
Right here you can see were Drakon sets the GRAVITY speed, The Jump speed and the climb speed. If you don't like the original jump height you can add maybe 2 to the JUMPVELOCITY:
Code:

GRAVITY = -9.8f;
    JUMPVELOCITY = 6.0f; //<- I set it to six now.
    CLIMBVELOCITY = 2.5f;


Ok so once you have done what you want go ahead and scroll down some more until you see:
Code:

cameraSpeed = 2.0f / 60.0f;
    cameraMoveSpeed = 4.0f/ 60.0f;

This sets the camera speed. (obviously )
Now pay attention. setting the SECOND NUMBER up will make your camera move SLOWER. EX.

Code:
cameraSpeed = 2.0f / 100.0f;

is slower then
Code:

cameraSpeed = 2.0f / 40.0f;


Now you should have an understanding of how to change things. Obviously these are simpler things to change. more advanced things require C/C++ knowledge. I am not giving a class on C/C++

Compiling the source:
Ok now you have made your changes, how do you compile it?
simple. (or not so simple)
first you must download PSPSDK
Install it.

--You can also look at the readme in your Lamecraft source file.
Now that it is installed goto your lamecraft source folder.

We must now compile the Music library.

Open the folder inside it called 3libs.

double click the file called "compile.bat"

once it is finished compiling goto your pspsdk folder (C:/PSPSDK)
now goto
PSP>include
create a folder called noisepp
and copy all the files with the extension of .h to there (C:/pspsdk/psp/include/noisepp)

now go back to the route pspsdk folder and copy the file libNoisepp.a to
C:/pspsdk/psp/lib

now you can go to the source of lamecraft and click on compile. It should compile smoothly (with a warning or two)

Congrats you have modded Lamecraft!

HINTS:
Don't replace your original Eboot.
Don't edit things you don't understand
Rainy
Rainy
Admin

Posts : 61
Reputation : -3
Join date : 2011-11-02
Age : 28
Location : Finland

https://lamecraft.palstani.com

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum