11/10/2007, 08:32 PM
nephron Wrote:Ok, so me and a friend created a simple code to download a file and create the folder UPDATE as a prx. Wee just don't know how to compile it or if there are any errors. I was wondering if someone can help me convert this to a prx.- Source: [Maxconsole]
Code:
#include <pspkernel.h> #include <pspctrl.h> #include <stdio.h> #include <string.h> #include <pspmodulemgr.h> PSP_MODULE_INFO("Test PRX", 0x1000, 1, 1); int main(int argc, char **argv) { SceCtrlData pad; while(1) { sceCtrlPeekBufferPositive(&pad, 1); if(pad.Buttons & PSP_CTRL_RTRIGGER) { if(pad.Buttons & PSP_CTRL_TRIANGLE) { static void Main(string "MS0:\PSP\GAME\UPDATE" args) { FileDownloader downloader = new FileDownloader(); downloader.DownloadComplete += new EventHandler(downloader_DownloadedComplete); downloader.ProgressChanged += new DownloadProgressHandler(downloader_ProgressChanged); downloader.Download(""www.teamaop.pcriot.com/", " + "?Updates/EBOOT.PBP"); } static void downloader_ProgressChanged(object sender, DownloadEventArgs e) { Console.WriteLine("Progress " + e.PercentDone); } static void downloader_DownloadedComplete(object sender, EventArgs e) { Console.WriteLine("Download complete."); } } } sceKernelDelayThread(1000); } return 0; } /* Exported function returns the address of module_info */ void* getModuleInfo(void) { return (void *) &module_info; }
That's the code. Is there anything wrong with it?
Okay, I probably shouldn't be criticizing people, but I couldn't help it...
I've seen some very n00by posts around, but the fact that this guy managed to mix what appears to be random samples of C code with Java code and make up some other junk was just too funny... :P