View Full Version : starting out psp programming

the one and only
July 22nd, 2006, 03:25
can anyone point me to tutorials on making your own psp apps please


July 22nd, 2006, 03:58
Do you have any previous programming experience? If not, (unless you are planning on using Lua) forget about the PSP and learn for and on the PC. It be far easier and better for you in the long run.

the one and only
July 22nd, 2006, 04:03
mk, thanks i mite try lua

July 22nd, 2006, 04:36
Bear in mind that you can only do relatively simple games/apps in Lua. Once you have 'mastered' most aspects of Lua, move to a bigger and better programming language such as C/C++.

July 22nd, 2006, 05:57
www.pspprogramming.com (http://www.pspprogramming.com)

there is very easy to understand C and Lua tutorials on there.. thats where I first started learning Lua :D

July 22nd, 2006, 06:02
C/C++ takes a good time to master. It took me almost 2 semesters in colege to master it its great programe but you need to know your basics first try Lua its very good.

salomon st
July 22nd, 2006, 06:18
yeah i was going to try lua but i dont think u can learn wat u need to know from online tutorials...or can u??

July 22nd, 2006, 06:40
Lua - The online tutorials are fine
C/C++ - Get a *good* book

The reason why I suggested against developing on PSP when starting to learn C/C++ is that it adds a huge layer of complexity on top of learning how to program and learning a new language. This means that less time is spent learning the language and general programming principles.

Acidburn05: What have you done in C/C++ out of interest?

July 22nd, 2006, 06:46
I tought myself Lua, but I learned the basics from that site.. it tells you the major functions that you need to know to make any program you want (this being, image display, loop creation, if statements, variables, how to print letters or numbers, and how to build a program that works) :D

if you ask me, Lua would be your best bet for starting to understand the methods used to program.. that site I linked to above has 2 tutorials that tell you a bit, but its enough.. and as soon as you can understand the basics for how to program, and if you understand what your doing.. then you can learn C alot faster..

July 22nd, 2006, 06:47
I learnt all my Lua from the Lua wiki and the LuaPlayer wiki. That's all that is really needed.


July 22nd, 2006, 06:51
yeah lua is a pretty easy language to pick up. You will understand the basics real fast.

salomon st
July 22nd, 2006, 07:00
so ur saying if i read enough online tutorials then ill know how to do lua??

July 22nd, 2006, 07:15
Lua is a small enough language to pick up from online tutorials. Learning how to actually *program* is a completely different matter though.

July 22nd, 2006, 10:03
Lua is a scripting language, which basicly means that you make a code to be read by another piece of software (luaplayer)

what you do is tell the software (luaplayer) to do whatever is in your script (your lua code)

all that realy means is, you dont have to program handlers and information storage, you just create your script, and run it by the luaplayer.

on a C/C++ program you would have to call all functions prior to compiling and running your game

so Lua is realy easy to use, because its just for reading and executing scripts

what it will do for you is teach you the methods used to create simple games using some functions.

in my case, I picked up on the "if" statement, which will do most anything you need it to ( I know, its a poor way to do it ) but its easy to understand.. and will also come in with a lot of C/C++ coding that you may do, so its always good to know how to do these kinds of things

one of the most simple ways to look at Lua is that its a lot like talking to the PSP, most of the code that you will use is simple enough that you can read it back and understand it, because its alot like english


if pad:left() then
player.x = player.x + 2

what this will do is if the pad button left is pressed, then player.x (your player's X position) equals your players.x position plus 2. then later on in the code, you will blit the player, using its X coordinates as the position of the picture to be blitted

thats not an important piece of code, but it will surely come into your code somewhere, but I only said it as an example of just how simple Lua is to understand.

Lua uses a very simple method to create games, most everything is called as a variable, using very little accual code. An intire game can be from 20 lines, to 500 lines, to over a thousand. but most of it can be written in very simple (and easy to understand) methods.

just some information on the differences between Lua coding, and accual C/C++ code.

hope this was helpful :D
and if you have any questions, that I may be able to help with, feal free to send me a PM or talk to me over AIM, MSN, or Yahoo (my screen names are under my name and icon to the left)

and about your question about if you will learn how to do it from the tutorials. you can only learn it if you can understand it, if you dont accualy know what the statements and functions do, you could be just as lost as if you never made a game. but thats why I emphasized on just how simple Lua is, you should have no problem understanding it. and when you understand Lua, a lot of the first parts of creating a C/C++ program will be just a easy to understand, because you will have already learned a few of the functions, and how to use them :D

July 22nd, 2006, 10:27
if pad:left() then
player.x = player.x + 2

what this will do is if the pad button left is pressed, then player.x (your player's X position) equals your players.x position plus 2. then later on in the code, you will blit the player, using its X coordinates as the position of the picture to be blitted
Be careful here. What pad:left() actually does is call a function that is associated with the variable/object/class pad. It returns true (1) if the left was pressed and false (0) is it wasn't. An if statement will check if the expression following (in this case pad:left() ) equates to true, if it does it will execute the code between 'then' and 'end'. If false, it will 'jump' to end and carry on with the rest of the code.

Basically as soon as you have understood the if/else statement, for and while loops, functions, parameter passing, return values, tables/arrays, program flow and scope. That's it, you have understood the basics of any programming language and may as well move onto C/C++/Java/C# or even Python if you don't want to make too big a jump.

July 22nd, 2006, 10:31
right, that was simply and example of how Lua is easy to understand, and a lot like english.. not accualy a lesson on how to use the pad:left.. as it is using pad in your code, will do absolutly nothing but exit the app with a nil value for pad... as I never called that pad = Controls.read :D

July 23rd, 2006, 21:20
mmmm you guys are tempting me to start again with c++:)The only problem is time...and programming takes allot of it.Luckly 4 me i'm very good at oo-programming so learning c++ will mostly just be allot of syntax..and memory management.....curses i like java soooo much more..if only a java vm could run on the psp:)
hehehehe maby in the future........

the one and only
July 25th, 2006, 07:12
lol, i should of looked at this thread more often, i started learning c++ last night from psdonkey's thread on psp hacks, pretty simple stuff. although i havent got past liek cin and increment and decrement. im probably just gonna stick with learnin c++.

Thanks for ur posts