w00t, GTA: LCS uses Lua!

Discuss using and improving Lua and the Lua Player specific to the PSP.

Moderators: Shine, Insert_witty_name

Post Reply
Gary13579
Posts: 93
Joined: Mon Aug 15, 2005 7:43 am

w00t, GTA: LCS uses Lua!

Post by Gary13579 »

I was poking around the GTA ISO just a few minutes ago, looking for what videos to rip to get it to work.
A few folders down, I noticed something weird..

There is a folder PSP_GAME/USRDIR/LUASCRIPTS in the ISO!
I've tried editing the files, and it looks like they are compiled somehow, but still... WOW.

Now, if we can get someone more expeirienced to de-compile these files, it may be possible to make custom game types :D

Files in here include CAPTRUETHEFLAG.LUA.LC, COMMENTARY.LUA.LC, PICKUPS.LUA.LC, STDLIB.LUA.LC, SPAWN.LUA.LC, and others.
Check out the ISO if you can.

Sorry for posting this here, but since it is PSP related, and Lua related, it just made sense..
Mr Billy
Posts: 10
Joined: Wed Oct 26, 2005 10:13 am

Post by Mr Billy »

hmmm... why would a big game developer use a high end language for their games? lua is a great language, but it cant compare to c or c++ in game programming. its like using visual basic to make a direct x game. it just shouldnt b done.

can anyone that has LCS confirm that this is truely lua code. if so, let the hacking begin!
"There is no spoone"
-The Matricks
Gary13579
Posts: 93
Joined: Mon Aug 15, 2005 7:43 am

Post by Gary13579 »

I don't think you understand me..
Only certain parts of the game use Lua, and the rest is C++.

Maybe they let their 12 year old kids code parts of the game, but they couldn't understand C++ :) ??
Mr Billy
Posts: 10
Joined: Wed Oct 26, 2005 10:13 am

Post by Mr Billy »

no i understood you that its only a small part of the game, but i still wonder why they would use a high end language.
"There is no spoone"
-The Matricks
cheriff
Regular
Posts: 258
Joined: Wed Jun 23, 2004 5:35 pm
Location: Sydney.au

Post by cheriff »

for things like scripting cutscenes, game rules, etc.. makes dev cycle much quicker if you dont have to rebuild after every change - they just reload the script. (possibly even keeping a build of the game running)
Also, doing things like this lua eases the coder/artist gap. The hardcore c guys provide a nice lua interface to the game engine so the level designers and cutscene animators, etc can do their thang without too much fuss.
Damn, I need a decent signature!
bengarney
Posts: 24
Joined: Sat Oct 22, 2005 6:48 pm

Post by bengarney »

Having scripting languages in your game is a time-honored tradition - almost every major game engine has a scripting language embedded in it. LUA is a popular choice because it's flexible and easily embedded though many engines have custom languages that fit their need more exactly.

It's a good move - scripting languages let artists & other non-coders get more easily involved, lets you do rapid test cycles without recompiles (for instance, in an XBox 360 title I work with, we can telnet into a running game and issue script commands to tweak game behavior), and often makes the game more robust as it's easier to recover from a scripting error.

Scripting languages can also carry the benefit of letting you port easily - just get the core runtime of your game going and the scripts "just work." The game engine I work with is neat because once we get it up and running on a platform, you can run the exact same game code on that platform as you do on any other; they're even network compatible.

Scripting languages rule. :)
LuMo
Posts: 410
Joined: Sun Aug 21, 2005 2:45 am
Location: Austria
Contact:

Post by LuMo »

you can compile lua scripts to binary using luac, maybe (i don't know) you can decompile it again (as it is possible in JAVA)

greets
lumo
"Good artists copy, great artists steal."
Pablo Picasso
go2lumo.com
bengarney
Posts: 24
Joined: Sat Oct 22, 2005 6:48 pm

Post by bengarney »

Worst case, you can dump the LUA bytecode - it's most likely higher level than normal assembly, and the compiler's typically a lot less smart, so you should be able to easily work out what's going on with some pencil & paper work.
Post Reply