ProQuake for PSP: Adding sv_cheats?

Need help with a tutorial found on InsideQC.com? Post here.
jastolze
Posts: 22
Joined: Tue Feb 08, 2011 11:31 am
Contact:

ProQuake for PSP: Adding sv_cheats?

Post by jastolze »

Hi, I'm Jastolze and I'm (somewhat) new here. My question is simple, and I believe the answer is also.
My question is: How to implement the sv_cheats cvar (or whatever it's called ; 0=No Cheats, 1=Cheats Enabled) I know I need the source for this, but I don't know a couple of things:
1. What compiler should I use?
2. Which part of the source is the proper place to put it? (what .h or .c file)
3. What would the Cvar need to look like to be recognized by the engine?
I DO NOT know ANY programming languages, but am willing to learn for a purpose such as this. I know I may sound annoying attempting to make cheats enabled, but Quakeworld engines have this command, so why not regular Quake? If someone is willing to help me with this, it will be greatly appreciated! :D

P.S: I would also like to know how to compile for a PSP slim version if at all possible, and how to allocate more ram.

Thanks,
- Jastolze
EDIT: I actually wanted to use GLQuake's engine, not ProQuake's.
Spike
Posts: 2914
Joined: Fri Nov 05, 2004 3:12 am
Location: UK
Contact:

Re: ProQuake for PSP: Adding sv_cheats?

Post by Spike »

find an existing cvar. definition, registration, and use. along with editing the Host_God_f command or whatever its called.
jastolze
Posts: 22
Joined: Tue Feb 08, 2011 11:31 am
Contact:

Re: ProQuake for PSP: Adding sv_cheats?

Post by jastolze »

Spike wrote:find an existing cvar. definition, registration, and use. along with editing the Host_God_f command or whatever its called.
Thanks, but could you be a little more specific? I needed to know where, or what file to put it in, and I was told Cygwin was the compiler to use, correct? Oh, and I need to know what Exactly it should look like when I enable sv_cheats. I'm a noob when it comes to programming, so please bear with me. :( I'll probably have more questions after this, too. XD
EDIT: I'm assuming you're talking about this: if (pr_global_struct->deathmatch && !host_client->privileged)return; <<< I should delete this part, right? For it to enable god mode in MP? (and I'm not playing online, but against bots)
It starts on line 108, if you're curious
http://www.nanobit.net/doxy/quake1/host ... ource.html
EDIT 2: I need the source for GLQUake, where could I find that. and does it need to be the one for PSP?
Baker
Posts: 3666
Joined: Tue Mar 14, 2006 5:15 am

Re: ProQuake for PSP: Adding sv_cheats?

Post by Baker »

If you want to get something to compile on Windows that is rather painless:

http://forums.inside3d.com/viewtopic.php?t=2937
The night is young. How else can I annoy the world before sunsrise? 8) Inquisitive minds want to know ! And if they don't -- well like that ever has stopped me before ..
jastolze
Posts: 22
Joined: Tue Feb 08, 2011 11:31 am
Contact:

Re: ProQuake for PSP: Adding sv_cheats?

Post by jastolze »

Thanks, Baker!
Hey, how do you compile as an eboot? It doesn't say anything about compiling for PSP, or does it not matter? Sorry for being noobish, lol.
Baker
Posts: 3666
Joined: Tue Mar 14, 2006 5:15 am

Re: ProQuake for PSP: Adding sv_cheats?

Post by Baker »

jastolze wrote:Thanks, Baker!
Hey, how do you compile as an eboot? It doesn't say anything about compiling for PSP, or does it not matter? Sorry for being noobish, lol.
The above will not compile on for the PSP. There is no exact same codebase engine that is the same for Windows and the PSP, although both the Kurok PSP engine and ProQuake 4.70 are somewhat close. I linked you the above so you can get the idea of compiling an engine (even if that is just for Windows).

A PSP engine is its own deal.

A good place to start would be the "Compiling for the PSP" thread I linked you using the Kurok engine (not the GLQuake one). You think you want the GLQuake one, but that is because you don't know any better (there are like 30 missing things in that PSP GLQuake engine, the Kurok one is far better).

There aren't any shortcuts, to compile for the PSP you will have to get your hands dirty and read the "Compiling for the PSP thread" in detail. Once you get it compile the first time and then once you get it to run on PSP, life is far easier.
The night is young. How else can I annoy the world before sunsrise? 8) Inquisitive minds want to know ! And if they don't -- well like that ever has stopped me before ..
jastolze
Posts: 22
Joined: Tue Feb 08, 2011 11:31 am
Contact:

Re: ProQuake for PSP: Adding sv_cheats?

Post by jastolze »

Baker wrote:
jastolze wrote:Thanks, Baker!
Hey, how do you compile as an eboot? It doesn't say anything about compiling for PSP, or does it not matter? Sorry for being noobish, lol.
The above will not compile on for the PSP. There is no exact same codebase engine that is the same for Windows and the PSP, although both the Kurok PSP engine and ProQuake 4.70 are somewhat close. I linked you the above so you can get the idea of compiling an engine (even if that is just for Windows).

A PSP engine is its own deal.

A good place to start would be the "Compiling for the PSP" thread I linked you using the Kurok engine (not the GLQuake one). You think you want the GLQuake one, but that is because you don't know any better (there are like 30 missing things in that PSP GLQuake engine, the Kurok one is far better).

There aren't any shortcuts, to compile for the PSP you will have to get your hands dirty and read the "Compiling for the PSP thread" in detail. Once you get it compile the first time and then once you get it to run on PSP, life is far easier.
Okay, so I have a couple of questions regarding compiling on the PSP:
1. So, I've heard compiling ProQuake and Kurok for the PSP. Which one would be easier and takes less time to compile.
2. What do I use to compile? I currently have Cygwin, Code Blocks, and DevCPP. I don't want to keep installing random things just to find out that I ended up needing a different compiler. If it is in fact Cwgwin, I don't know how to use it, all I see is a terminal... I've heard that I need PSP Toolchain, but I don't know how to use it on Cwgwin. :(
3. For the sake of compiling, what should I type or delete from the host_cmd? I currently have deleted this:
if (pr_global_struct->deathmatch)
return;
I deleted it assuming that's the part that disables god mode in Deathmatch modes. Am I right to do this? If not, please explain what I did wrong, or need to do.

Thanks for all the help, I think I can eventually figure this out. I just needed to know if I'm doing things right, and would like someone to explain the above three issues.

Thanks again,
- Jastolze
Edit: I seem to have trouble finding the Kurok PSP source. I went to Bladebattles.com (their main site) and I only see a list of the source files... I can't download them. :/
Edit 2: Hey, does anyone know where I can find a step by step tutorial for compiling the Kurok engine. I saw the one backer linked to me, but it wasn't very specific.
Baker
Posts: 3666
Joined: Tue Mar 14, 2006 5:15 am

Re: ProQuake for PSP: Adding sv_cheats?

Post by Baker »

jastolze wrote:2. What do I use to compile? I currently have Cygwin, Code Blocks, and DevCPP. I don't want to keep installing random things just to find out that I ended up needing a different compiler. If it is in fact Cwgwin, I don't know how to use it, all I see is a terminal... I've heard that I need PSP Toolchain, but I don't know how to use it on Cwgwin. :(
Everything is documented quite nicely in http://forums.inside3d.com/viewtopic.php?t=1667 in Team Xlink's post, using the download I posted near the end of the thread as a mirror of his defunct Megaupload one. Your questions are invalid if you follow the instructions Xlink posted, cygwin.rar is the tool chain, etc. IDE? There isn't an IDE, you compile via the command line like documented by Xlink, see the "make" part.
Edit: I seem to have trouble finding the Kurok PSP source. I went to Bladebattles.com (their main site) and I only see a list of the source files... I can't download them. :/
Edit 2: Hey, does anyone know where I can find a step by step tutorial for compiling the Kurok engine. I saw the one backer linked to me, but it wasn't very specific.
http://forums.inside3d.com/viewtopic.php?f=9&t=1373

Use the URL where you found that list of source files.
The night is young. How else can I annoy the world before sunsrise? 8) Inquisitive minds want to know ! And if they don't -- well like that ever has stopped me before ..
r00k
Posts: 1111
Joined: Sat Nov 13, 2004 10:39 pm

Re: ProQuake for PSP: Adding sv_cheats?

Post by r00k »

Thanks, but could you be a little more specific? \

I need cut/paste code now! ;) PSP = kids with thumbs... only.
jastolze
Posts: 22
Joined: Tue Feb 08, 2011 11:31 am
Contact:

Re: ProQuake for PSP: Adding sv_cheats?

Post by jastolze »

Baker wrote:
jastolze wrote:2. What do I use to compile? I currently have Cygwin, Code Blocks, and DevCPP. I don't want to keep installing random things just to find out that I ended up needing a different compiler. If it is in fact Cwgwin, I don't know how to use it, all I see is a terminal... I've heard that I need PSP Toolchain, but I don't know how to use it on Cwgwin. :(
Everything is documented quite nicely in http://forums.inside3d.com/viewtopic.php?t=1667 in Team Xlink's post, using the download I posted near the end of the thread as a mirror of his defunct Megaupload one. Your questions are invalid if you follow the instructions Xlink posted, cygwin.rar is the tool chain, etc. IDE? There isn't an IDE, you compile via the command line like documented by Xlink, see the "make" part.
Edit: I seem to have trouble finding the Kurok PSP source. I went to Bladebattles.com (their main site) and I only see a list of the source files... I can't download them. :/
Edit 2: Hey, does anyone know where I can find a step by step tutorial for compiling the Kurok engine. I saw the one backer linked to me, but it wasn't very specific.
http://forums.inside3d.com/viewtopic.php?f=9&t=1373

Use the URL where you found that list of source files.
Thanks for all your help, Baker. I made it all the way to the makefile point in cygwin, but for some reason, my anti-virus won't let PSP-Config run, and force closes cygwin... Is it even necessary to run? It's located under: Cygwin/usr/local/pspdev/bin/ if that makes any difference. There's also a bunch of other .exe files in the bin folder? What do these do, and why are they even necessary? Other than that, I should be good to go if that didn't occur. Thanks again!
Edit: K, I got past the first problem, but when I try to makefile, it says at the bottom: FATAL: Can't create slim/psp/clippings.o: Permission denied??? I have full access over my computer, but it won't let me do anything...
Baker
Posts: 3666
Joined: Tue Mar 14, 2006 5:15 am

Re: ProQuake for PSP: Adding sv_cheats?

Post by Baker »

You will almost certainly have to disable UAC to run Cygwin. Windows 7 or Vista don't let Cygwin do all the Cygwin stuff with all the restrictions UAC places on folders and file writes and such.

Here is a Windows Vista oriented link to disable UAC, if using Windows 7 Google it:

http://www.howtogeek.com/howto/windows- ... ows-vista/
jastolze wrote:Thanks for all your help, Baker. I made it all the way to the makefile point in cygwin
Cool :D Yeah the only way to compile is by doing it.

If you want to get a rough idea of how to implement sv_cheats, download the source for an engine with support for that and use something like TextPad that has full path text search (you know, like can search for text matches in a whole folder + subfolders and conveniently display results) and search for "sv_cheats.value" or "sv_cheats.integer". You'll probably only get 3-4 matches and those are what you will need to implement.
The night is young. How else can I annoy the world before sunsrise? 8) Inquisitive minds want to know ! And if they don't -- well like that ever has stopped me before ..
jastolze
Posts: 22
Joined: Tue Feb 08, 2011 11:31 am
Contact:

Re: ProQuake for PSP: Adding sv_cheats?

Post by jastolze »

Baker wrote:You will almost certainly have to disable UAC to run Cygwin. Windows 7 or Vista don't let Cygwin do all the Cygwin stuff with all the restrictions UAC places on folders and file writes and such.

Here is a Windows Vista oriented link to disable UAC, if using Windows 7 Google it:

http://www.howtogeek.com/howto/windows- ... ows-vista/
jastolze wrote:Thanks for all your help, Baker. I made it all the way to the makefile point in cygwin
Cool :D Yeah the only way to compile is by doing it.

If you want to get a rough idea of how to implement sv_cheats, download the source for an engine with support for that and use something like TextPad that has full path text search (you know, like can search for text matches in a whole folder + subfolders and conveniently display results) and search for "sv_cheats.value" or "sv_cheats.integer". You'll probably only get 3-4 matches and those are what you will need to implement.
Good find about the UAC. Oh, but I'm now getting an error that it didn't discuss in the tutorial you linked me. I get this: "make *** [slim/psp/network_psp.o]
Error 1" and it takes me back to where I started. I know I'm doing something wrong, and I googled it, but not too many related links...
Hey Hey Hey, I think I got it to compile :D. Now, I wonder what directory the eboot is in???
jastolze
Posts: 22
Joined: Tue Feb 08, 2011 11:31 am
Contact:

Re: ProQuake for PSP: Adding sv_cheats?

Post by jastolze »

Hi sorry for bumping, but I'm trying to compile a slim version of mexi's revamped engine source for a friend. But I get this error: Make *** No rule to make target 'cl_cam.o, needed by release/gl/cl_cam.o Stop. I haven't done this since early May, so I know I'm doing something simple wrong... But what? Here's what I did.
1. Opened Cygwin.bat
2. Type in the terminal: cd c:/cygwin/1/Kurok/PSP.
3. Type 'make'
That''s when it gave me that error. I read that tutorial for compiling Kurok, since this IS a modified kurok engine, I thought I'd follow that.
Please help. Thanks!
Edit: Also, I don't see the .O files anywhere under the slim directory. I do, however see them inside the normal folder, if that makes any difference.
Spike
Posts: 2914
Joined: Fri Nov 05, 2004 3:12 am
Location: UK
Contact:

Re: ProQuake for PSP: Adding sv_cheats?

Post by Spike »

almost sounds like a typo in your makefile. sounds like the rule depends upon cl_cam.o instead of cl_cam.c
jastolze
Posts: 22
Joined: Tue Feb 08, 2011 11:31 am
Contact:

Re: ProQuake for PSP: Adding sv_cheats?

Post by jastolze »

Spike wrote:almost sounds like a typo in your makefile. sounds like the rule depends upon cl_cam.o instead of cl_cam.c
I found out what the issue was with that, I typed 'make' not make -f makefilenormal. Now I have a new issue: It says: make: psp-config: command not found. It also says the psp sdk wasn't found. I'm assuming that the psp-config thing was because i forgot something when installing cygwin. also, I'm not sure what it means by psp sdk? Thanks in advance!
Post Reply