Seite 295 von 340 ErsteErste ... 195 245 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 ... LetzteLetzte
Zeige Ergebnis 8.821 bis 8.850 von 10174

C/C++ Programming Help Thread

This is a discussion on C/C++ Programming Help Thread within the PSP Development Forum forums, part of the PSP Development, Hacks, and Homebrew category; Zitat von MiKeY188 Well then buy some books. If you want a basic website use .html if you want a ...

  
  1. #8821
    banned 4 LIFE
    Points: 14.513, Level: 78
    Level completed: 16%, Points required for next Level: 337
    Overall activity: 0%

    Registriert seit
    Apr 2007
    Ort
    Jupiter
    Beiträge
    3
    Points
    14.513
    Level
    78
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von MiKeY188 Beitrag anzeigen
    Well then buy some books. If you want a basic website use .html if you want a complex website use .php
    ...


    wat.


    Just get out now.


    But yes, Javascript and PHP are good for learning the basics of programming.



  2. #8822
    Oppressed by the man
    Points: 5.684, Level: 48
    Level completed: 67%, Points required for next Level: 66
    Overall activity: 0%

    Registriert seit
    Jul 2008
    Ort
    So Cal
    Beiträge
    323
    Points
    5.684
    Level
    48
    Downloads
    0
    Uploads
    0

    Standard

    Ok I know simple .html gotta lear advanvced and move my way up
    welll thanks anyways guys...=]

  3. #8823
    QJ Gamer Silver
    Points: 6.763, Level: 54
    Level completed: 7%, Points required for next Level: 187
    Overall activity: 0%

    Registriert seit
    Jul 2006
    Beiträge
    413
    Points
    6.763
    Level
    54
    Downloads
    0
    Uploads
    0

    Standard

    So how can I tell how many threads are being run in-game? That way I can stop all working threads except my PRX.
    Atheist, because I just won't believe in what doesn't show itself to me.

  4. #8824
    QJ Gamer Bronze
    Points: 6.517, Level: 52
    Level completed: 84%, Points required for next Level: 33
    Overall activity: 0%

    Registriert seit
    Apr 2008
    Ort
    Ireland
    Beiträge
    978
    Points
    6.517
    Level
    52
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von explosions Beitrag anzeigen
    ...


    wat.


    Just get out now.


    But yes, Javascript and PHP are good for learning the basics of programming.
    WTF? Most big sites are coded in .PHP

  5. #8825
    banned 4 LIFE
    Points: 14.513, Level: 78
    Level completed: 16%, Points required for next Level: 337
    Overall activity: 0%

    Registriert seit
    Apr 2007
    Ort
    Jupiter
    Beiträge
    3
    Points
    14.513
    Level
    78
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von MiKeY188 Beitrag anzeigen
    WTF? Most big sites are coded in .PHP
    yeah....

    But, you seem to not know much about it.

    This is the C/C++ thread anyway, so I'm gonna gtfo, and so should you.

  6. #8826
    QJ Gamer Silver
    Points: 10.263, Level: 67
    Level completed: 54%, Points required for next Level: 187
    Overall activity: 0%

    Registriert seit
    Jun 2006
    Ort
    UK
    Beiträge
    2.326
    Points
    10.263
    Level
    67
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von Iconic_187 Beitrag anzeigen
    What are some of the basic things I have to learn before I start learning C/C++ when I know nothing about it...?
    someone please help =/
    We just been through this with another user.
    C or LUA
    how to make an obstacle?

  7. #8827
    QJ Gamer Bronze
    Points: 6.517, Level: 52
    Level completed: 84%, Points required for next Level: 33
    Overall activity: 0%

    Registriert seit
    Apr 2008
    Ort
    Ireland
    Beiträge
    978
    Points
    6.517
    Level
    52
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von explosions Beitrag anzeigen
    yeah....

    But, you seem to not know much about it.

    This is the C/C++ thread anyway, so I'm gonna gtfo, and so should you.
    i don't xD
    yeah ill follow you ;)

  8. #8828
    QJ Gamer Blue
    Points: 4.268, Level: 41
    Level completed: 59%, Points required for next Level: 82
    Overall activity: 0%

    Registriert seit
    Apr 2008
    Beiträge
    497
    Points
    4.268
    Level
    41
    Downloads
    0
    Uploads
    0

    Standard

    hey question, I just learning C++ and I was wondering how to do button input for PSP, is it kinda like cin >> cross?? I know there is more to it as you need to define cross, but please explain, or give me a tut for C++ specifically for PSP :)

  9. #8829
    QJ Gamer Silver
    Points: 6.763, Level: 54
    Level completed: 7%, Points required for next Level: 187
    Overall activity: 0%

    Registriert seit
    Jul 2006
    Beiträge
    413
    Points
    6.763
    Level
    54
    Downloads
    0
    Uploads
    0

    Standard

    Can someone explain how to unsuspend user threads after calling this function:
    sceKernelSuspendAllUserTh reads();

    Thanks.
    -=Double Post Merge =-
    Zitat Zitat von PSProgramer Beitrag anzeigen
    hey question, I just learning C++ and I was wondering how to do button input for PSP, is it kinda like cin >> cross?? I know there is more to it as you need to define cross, but please explain, or give me a tut for C++ specifically for PSP :)
    http://www.psp-programming.com/tutorials/c/lesson03.htm

    Hope that helps. There are other tutorials there, as well.
    Geändert von Durka Durka Mahn (08-04-2008 um 06:11 PM Uhr) Grund: Automerged Doublepost
    Atheist, because I just won't believe in what doesn't show itself to me.

  10. #8830
    lol
    Points: 20.859, Level: 91
    Level completed: 2%, Points required for next Level: 491
    Overall activity: 0%

    Registriert seit
    Aug 2006
    Ort
    Whittier, CA
    Beiträge
    5.791
    Points
    20.859
    Level
    91
    Downloads
    0
    Uploads
    0

    Standard

    sceKernelResumeThread();

    EDIT: nvm, this only works with sceKernelSuspendThread

    Anyways, I know 0x1000 is kernel mode, but what other modes are there besides kernel and user?
    I think I've seen something like 0x0800 is vsh or something similar.
    Geändert von Anti-QuickJay (08-04-2008 um 08:36 PM Uhr)

  11. #8831
    Points: 2.658, Level: 31
    Level completed: 39%, Points required for next Level: 92
    Overall activity: 0%

    Registriert seit
    Apr 2008
    Beiträge
    47
    Points
    2.658
    Level
    31
    Downloads
    0
    Uploads
    0

    Standard

    @PSProgrammer:
    Go thorugh the C tutorials at psp-programming.com. There's a function in pspctrl.h that fetches a btimask of the currently pressed keys. I think it's 'pspCtrlReadBufferPositiv e(PspCtrlData*, 1)'. Then you use the enumerated constants in pspctrl.h and compare them to the PspCtrlData by using & (bitwise and).

    example:
    Code:
    PspCtrlData pad;
    pspCtrlReadBufferPositive(&pad, 1);
    if(pad & PSP_CTRL_CROSS) {
      //do something
    }
    You should check the lib, though, to make sure I got the function and struct names right, but really you should read the tutorials. They go over all that stuff.

  12. #8832
    QJ Gamer Silver
    Points: 6.763, Level: 54
    Level completed: 7%, Points required for next Level: 187
    Overall activity: 0%

    Registriert seit
    Jul 2006
    Beiträge
    413
    Points
    6.763
    Level
    54
    Downloads
    0
    Uploads
    0

    Standard

    What is user mode then? I really need to know to get my program working... :/
    Atheist, because I just won't believe in what doesn't show itself to me.

  13. #8833
    QJ Gamer Gold
    Points: 17.453, Level: 84
    Level completed: 21%, Points required for next Level: 397
    Overall activity: 0%

    Registriert seit
    Jul 2005
    Ort
    everywhere
    Beiträge
    3.526
    Points
    17.453
    Level
    84
    Downloads
    1
    Uploads
    0

    Standard

    user mode is simple that, "user mode" it doesn't allow direct access to the hardware(all be it that their are now user functions to allow most access to the hardware), where's their's also "kernel mode", which allows direct access to the hardware, however any 3xx kernel can not be started in this mode

    kernel mode:
    PSP_MODULE_INFO("Kernel mode", 0x1000, 0, 1); //the 0x1000 tells the psp it's a kernel app and can not be started in any 3xx fw

    user mode:
    PSP_MODULE_INFO("user moder", 0, 0, 1); //the first 0 denotes user mode and is what can only be started in 3xx fw atm

    now than
    1. Failed....again...
    2. http://slicer.gibbocool.com/ stay updated on all my projects
    3. it'll be 5 years in june, that's nearly 1/4 of my life on this planet that i've visited these forums, what a ride it has been

  14. #8834
    QJ Gamer Green
    Points: 5.712, Level: 48
    Level completed: 81%, Points required for next Level: 38
    Overall activity: 0%

    Registriert seit
    Jul 2006
    Ort
    USA SC/NC
    Beiträge
    699
    Points
    5.712
    Level
    48
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von slicer4ever Beitrag anzeigen
    user mode is simple that, "user mode" it doesn't allow direct access to the hardware(all be it that their are now user functions to allow most access to the hardware), where's their's also "kernel mode", which allows direct access to the hardware, however any 3xx kernel can not be started in this mode

    kernel mode:
    PSP_MODULE_INFO("Kernel mode", 0x1000, 0, 1); //the 0x1000 tells the psp it's a kernel app and can not be started in any 3xx fw

    user mode:
    PSP_MODULE_INFO("user moder", 0, 0, 1); //the first 0 denotes user mode and is what can only be started in 3xx fw atm

    now than
    ... wrong. if you don't know WHAT you are talking about then DO NOT try to explain something.
    [CODE]Random Facts:
    irc://irc.malloc.us #wtf #**********
    [/CODE]

    [SIZE="6"][FONT="Century Gothic"][COLOR="Blue"][URL="http://forums.**********.net"]http://forums.**********.net[/URL][/COLOR][/FONT][/SIZE]

  15. #8835
    QJ Gamer Gold
    Points: 17.453, Level: 84
    Level completed: 21%, Points required for next Level: 397
    Overall activity: 0%

    Registriert seit
    Jul 2005
    Ort
    everywhere
    Beiträge
    3.526
    Points
    17.453
    Level
    84
    Downloads
    1
    Uploads
    0

    Standard

    than do explain it
    1. Failed....again...
    2. http://slicer.gibbocool.com/ stay updated on all my projects
    3. it'll be 5 years in june, that's nearly 1/4 of my life on this planet that i've visited these forums, what a ride it has been

  16. #8836
    words are stones in my <3
    Points: 35.274, Level: 100
    Level completed: 0%, Points required for next Level: 0
    Overall activity: 0%

    Registriert seit
    Jul 2005
    Ort
    Spokane
    Beiträge
    5.008
    Points
    35.274
    Level
    100
    My Mood
    Lonely
    Downloads
    1
    Uploads
    0

    Standard

    Yes either Moca is incredibly ignorant to not explain it after disagreeing with you or he is describing himself.

    I wrote up a relatively long post at psp-hacks to someone asking a very similar question, I don't want to type it all out again so i'll try to search for it

    ...at what speed must I live.. to be able to see you again?...

    Projects

    You can support my Open World 3D RPG for PSP by voting for it here


  17. #8837
    QJ Gamer Silver
    Points: 6.763, Level: 54
    Level completed: 7%, Points required for next Level: 187
    Overall activity: 0%

    Registriert seit
    Jul 2006
    Beiträge
    413
    Points
    6.763
    Level
    54
    Downloads
    0
    Uploads
    0

    Standard

    No, no, I'm not asking WHAT user mode is, I'm asking for the code. He said kernel was 0x1000 and that he thought VSH was 0x800..
    Atheist, because I just won't believe in what doesn't show itself to me.

  18. #8838
    QJ Gamer Gold
    Points: 17.453, Level: 84
    Level completed: 21%, Points required for next Level: 397
    Overall activity: 0%

    Registriert seit
    Jul 2005
    Ort
    everywhere
    Beiträge
    3.526
    Points
    17.453
    Level
    84
    Downloads
    1
    Uploads
    0

    Standard

    Zitat Zitat von slicer4ever
    Code:
    PSP_MODULE_INFO("user mode", 0, 0, 1); //the first 0 denotes user mode and is what can only be started in 3xx fw atm
    =-)
    1. Failed....again...
    2. http://slicer.gibbocool.com/ stay updated on all my projects
    3. it'll be 5 years in june, that's nearly 1/4 of my life on this planet that i've visited these forums, what a ride it has been

  19. #8839
    QJ Gamer Silver
    Points: 6.763, Level: 54
    Level completed: 7%, Points required for next Level: 187
    Overall activity: 0%

    Registriert seit
    Jul 2006
    Beiträge
    413
    Points
    6.763
    Level
    54
    Downloads
    0
    Uploads
    0

    Standard

    No, no, I need to resume user mode after calling this function:
    sceKernelSuspendAllUserTh reads();

    Anti-QJ said to use sceKernelResumeThread(); but that doesn't work with user mode...
    Atheist, because I just won't believe in what doesn't show itself to me.

  20. #8840
    QJ Gamer Gold
    Points: 17.453, Level: 84
    Level completed: 21%, Points required for next Level: 397
    Overall activity: 0%

    Registriert seit
    Jul 2005
    Ort
    everywhere
    Beiträge
    3.526
    Points
    17.453
    Level
    84
    Downloads
    1
    Uploads
    0

    Standard

    ahh, i'm sorry i didn't realize there was a conversation on the prior page, my bad, anywho it appears after a quick look at the documentation that sceKernelResumeThread resumes when used with sceKernelSuspendThread() function, however it appears that you can pass an thid parameter to sceKernelResumeThread, so that's as much as i know
    1. Failed....again...
    2. http://slicer.gibbocool.com/ stay updated on all my projects
    3. it'll be 5 years in june, that's nearly 1/4 of my life on this planet that i've visited these forums, what a ride it has been

  21. #8841
    Developer
    Points: 7.577, Level: 58
    Level completed: 14%, Points required for next Level: 173
    Overall activity: 0%

    Registriert seit
    Mar 2006
    Beiträge
    1.026
    Points
    7.577
    Level
    58
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von Durka Durka Mahn Beitrag anzeigen
    No, no, I need to resume user mode after calling this function:
    sceKernelSuspendAllUserTh reads();

    Anti-QJ said to use sceKernelResumeThread(); but that doesn't work with user mode...
    I already told you how to accomplish what you want on the other page.

    sceKernelSuspendAllUserTh reads() is not that.

    Stop trying to take shortcuts

    Check out my homebrew & C tutorials at http://insomniac.0x89.org/
    Coder formerly known as Insomniac197

    tshirtz: what is irshell ??
    Atarian_: it's where people who work for the IRS go when they die

  22. #8842
    QJ Gamer Silver
    Points: 6.763, Level: 54
    Level completed: 7%, Points required for next Level: 187
    Overall activity: 0%

    Registriert seit
    Jul 2006
    Beiträge
    413
    Points
    6.763
    Level
    54
    Downloads
    0
    Uploads
    0

    Standard

    Yes, but there is no way to resume the user threads using that function..

    I even tried using sceKernelSuspendThread but it didn't freeze the game like I need it to.
    Atheist, because I just won't believe in what doesn't show itself to me.

  23. #8843
    Developer
    Points: 7.577, Level: 58
    Level completed: 14%, Points required for next Level: 173
    Overall activity: 0%

    Registriert seit
    Mar 2006
    Beiträge
    1.026
    Points
    7.577
    Level
    58
    Downloads
    0
    Uploads
    0

    Standard

    Here is the source for taking a screenshot as a BMP file. It uses the functions I listed.

    I'm not sure where the code is from, I know it isn't mine - so credit to whoever the author is.

    Spoiler for Code:

    Code:
    #include <pspkernel.h>
    #include <psploadcore.h>
    #include <pspiofilemgr.h>
    #include <pspdisplay.h>
    #include <pspctrl.h>
    #include <stdio.h>
    #include <string.h>
    #include <png.h>
    
    PSP_MODULE_INFO("Screen Shot: BMP", 0x1000, 1, 0);
    PSP_MAIN_THREAD_ATTR(0);
    
    #define MAX_THREAD	64
    #define CAPTURE_SAVE_DIR "ms0:/PSP/PHOTO/capture"
    
    typedef unsigned char   BYTE;
    typedef unsigned short  WORD;
    typedef unsigned long   DWORD;
    typedef long            LONG;
    
    typedef struct tagBITMAPFILEHEADER {
       //    WORD    bfType;
            DWORD   bfSize;
            DWORD   bfReserved;
            DWORD   bfOffBits;
    } BITMAPFILEHEADER;
    
    typedef struct tagBITMAPINFOHEADER{
    	DWORD	biSize;
    	LONG	biWidth;
    	LONG	biHeight;
    	WORD	biPlanes;
    	WORD	biBitCount;
    	DWORD	biCompression;
    	DWORD	biSizeImage;
    	LONG	biXPelsPerMeter;
    	LONG	biYPelsPerMeter;
    	DWORD	biClrUsed;
    	DWORD	biClrImportant;
    } BITMAPINFOHEADER;
    
    
    /***************************************
    
    âÊñ*ÇBMPÉtÉ@ÉCÉãÇ…ï€ë∂
    
    ****************************************/
    void screenshot_BMP(const char* filename, char imageSize){
    	
    	int x, y;
    	int fd = sceIoOpen(filename, PSP_O_CREAT|PSP_O_WRONLY|PSP_O_TRUNC, 0777);
    	if(fd < 0){
    		return;
    	}
    
    	int pwidth, pheight, bufferwidth, pixelformat, unk;
    	unsigned int* vram32;
    	unsigned short* vram16;
    
    	//ÉfÉBÉXÉvÉåÉCèÓïÒéÊìæ
    	sceDisplayWaitVblankStart();
    	sceDisplayGetMode(&unk, &pwidth, &pheight);
    	sceDisplayGetFrameBuf((void*)&vram32, &bufferwidth, &pixelformat, &unk);
    	vram16 = (unsigned short*) vram32;
    		
    	//BMPÉwÉbÉ_çÏê¨
    	unsigned char bm[2], padding;
    	BITMAPFILEHEADER h1;
    	BITMAPINFOHEADER h2;
    	
    	//BMèëÇ´çûÇ›
    	bm[0] = 0x42;
    	bm[1] = 0x4D;
    	sceIoWrite(fd, bm, 2);
    
    	int pw = pwidth, ph = pheight;
    	if(imageSize > 0) pw /=2, ph /= 2;
    		
    	padding = (3*(pw/2) % 4);
    	h1.bfSize	= ((24*pw + padding)*ph)/8 + sizeof(BITMAPFILEHEADER) + sizeof(BITMAPINFOHEADER) + 2;
    	h1.bfReserved	= 0;
    	h1.bfOffBits	= 2 + sizeof(BITMAPFILEHEADER) + sizeof(BITMAPINFOHEADER);
    
    	h2.biSize	= sizeof(BITMAPINFOHEADER);
    	h2.biPlanes	= 1;
    	h2.biBitCount	= 24;
    	h2.biCompression 	= 0;
    	h2.biWidth	= pw;
    	h2.biHeight	= ph;
    	h2.biSizeImage	= ((24*pw + padding)*ph)/8;
    	h2.biXPelsPerMeter	= 0xEC4;
    	h2.biYPelsPerMeter	= 0xEC4;
    	h2.biClrUsed		= 0;
    	h2.biClrImportant	= 0;
    
    	//ÉwÉbÉ_èëÇ´çûÇ›
    	sceIoWrite(fd, &h1, sizeof(BITMAPFILEHEADER));
    	sceIoWrite(fd, &h2, sizeof(BITMAPINFOHEADER));
    	
    	
    //ÉXÉNÉäÅ[ÉìÇ24bitBMPâÊëúÇ…ïœä∑
    	SceUID mem = sceKernelAllocPartitionMemory(2, "block", 0, (3*pw + padding)*sizeof(unsigned char), NULL);
    	unsigned char *buf = (unsigned char*)sceKernelGetBlockHeadAddr(mem);
    //	unsigned char buf[3*pw + padding];
    
    	for(x = 0; x < padding; x++){
    		buf[3*pw + x] = 0;
    	}
    	for(y = (ph-1); y >= 0; y--){
    		int i;
    		for(i = 0, x = 0; x < pw; x++){
    			unsigned int color, offset = x + y*bufferwidth;
    			unsigned char r = 0, g = 0, b = 0;
    			if(imageSize) offset *= 2;
    
    			switch (pixelformat) {
    				case 0:	// 16-bit RGB 5:6:5
    					color = vram16[offset];
    					vram16[offset] ^= 0xFFFF;	//îΩì]
    					r = (color & 0x1f) << 3; 
    					g = ((color >> 5) & 0x3f) << 2 ;
    					b = ((color >> 11) & 0x1f) << 3 ;
    					break;
    				case 1:// 16-bit RGBA 5:5:5:1
    					color = vram16[offset];
    					vram16[offset] ^= 0x7FFF;	//îΩì]
    					r = (color & 0x1f) << 3; 
    					g = ((color >> 5) & 0x1f) << 3 ;
    					b = ((color >> 10) & 0x1f) << 3 ;
    					break;
    				case 2:// 16-bit RGBA 4:4:4:4
    					color = vram16[offset];
    					vram16[offset] ^= 0x0FFF;	//îΩì]
    					r = (color & 0xf) << 4; 
    					g = ((color >> 4) & 0xf) << 4 ;
    					b = ((color >> 8) & 0xf) << 4 ;
    					break;
    				case 3:// 32-bit RGBA 8:8:8:8
    					color = vram32[offset];
    					vram32[offset] ^= 0x00FFFFFF;	//îΩì]
    					r = color & 0xff; 
    					g = (color >> 8) & 0xff;
    					b = (color >> 16) & 0xff;
    					break;
    			}
    			buf[i++] = b;
    			buf[i++] = g;
    			buf[i++] = r;
    		}
    		sceIoWrite(fd, buf, 3*pw + padding);
    	}
    	sceKernelFreePartitionMemory(mem);
    //	sceIoWaitAsync(fd, NULL);
    	sceIoClose(fd);
    
    //êFÇå≥Ç…ñflÇ∑
    	for(y = 0; y < ph; y++){
    		int i;
    		for(i = 0, x = 0; x < pw; x++){
    			unsigned int offset = x + y*bufferwidth;
    			if(imageSize) offset *= 2;
    
    			switch (pixelformat) {
    				case 0:	// 16-bit RGB 5:6:5
    					vram16[offset] ^= 0xFFFF;	//îΩì]
    					break;
    				case 1:// 16-bit RGBA 5:5:5:1
    					vram16[offset] ^= 0x7FFF;	//îΩì]
    					break;
    				case 2:// 16-bit RGBA 4:4:4:4
    					vram16[offset] ^= 0x0FFF;
    					break;
    				case 3:// 32-bit RGBA 8:8:8:8
    					vram32[offset] ^= 0x00FFFFFF;
    					break;
    			}
    		}
    	}
    }
    
    
    int mainThread (SceSize args, void *argp){
    	unsigned int paddata_old = 0;
    	char file[64], flag = 0, size = 0;
    	int x, y, fd, count = 0, thread_count_start, thread_count_now;
    	SceUID thread_buf_start[MAX_THREAD], thread_buf_now[MAX_THREAD], myThread = sceKernelGetThreadId();
    	SceCtrlData paddata;
    	
    	sceKernelDelayThread(10000);
    	sceKernelGetThreadmanIdList(SCE_KERNEL_TMID_Thread, thread_buf_start, MAX_THREAD, &thread_count_start);
    
    	//ï€ë∂êÊÇÃÉfÉBÉåÉNÉgÉäÇÃçÏê¨
    	sceIoMkdir(CAPTURE_SAVE_DIR,0777);
    	
    	while(1){
    		sceCtrlPeekBufferPositive(&paddata, 1);
    		
    		if(paddata.Buttons != paddata_old){
    			//ÉXÉNÉäÅ[ÉìÉVÉáÉbÉg
    			if((flag > 0) && (paddata.Buttons & PSP_CTRL_NOTE)){
    				flag = 0;
    				size = 0;
    			}
    			else if((paddata.Buttons & PSP_CTRL_NOTE) || (flag > 0)){
    
    				//Vol-Ç*àÍèèÇ…âüÇ≥ÇÍǃǢÇΩÇÁâÊëúÇ4ï*ÇÃ1Ç…Ç∑ÇÈ
    				if(flag == 0){
    					if(paddata.Buttons & 0x00200000) size = 1;
    					else size = 0;
    				}
    				//NOTE+L+RÇ≈òAë±ÉLÉÉÉvÉ`ÉÉÉÇÅ[Éh
    				if((paddata.Buttons & (PSP_CTRL_LTRIGGER | PSP_CTRL_NOTE)) == (PSP_CTRL_LTRIGGER | PSP_CTRL_NOTE)){
    					flag = 1;//ON
    				}
    				// IdList Now
    				sceKernelGetThreadmanIdList(SCE_KERNEL_TMID_Thread, thread_buf_now, MAX_THREAD, &thread_count_now);
    
    				for(x = 0; x < thread_count_now; x++){
    					// thread id match 0 or 1
    					unsigned char match = 0;
    					SceUID tmp_thid = thread_buf_now[x];
    					for(y = 0; y < thread_count_start; y++){
    						if((tmp_thid == thread_buf_start[y]) || (tmp_thid == myThread)){
    							match = 1;
    							y = thread_count_start;
    						}
    					}
    					if(thread_count_start == 0) match = 1;
    					if(match == 0){
    						sceKernelSuspendThread(tmp_thid);
    					}
    
    				}
    					
    				
    				//ÉXÉNÉäÅ[ÉìÉVÉáÉbÉgÇÃèàóù
    				while(1){
    					sprintf(file, "%s/snap%03d.bmp", CAPTURE_SAVE_DIR, count);
    					fd = sceIoOpen(file, PSP_O_RDONLY, 0644);
    					if(fd < 0){
    						sceIoClose(fd);
    						break;
    					}
    					sceIoClose(fd);
    					count++;
    				}
    				screenshot_BMP(file, size);
    				
    				// ÉXÉåÉbÉhÇçƒäJ
    				for(x = 0; x < thread_count_now; x++){
    					// thread id match 0 or 1
    					unsigned char match = 0;
    					SceUID tmp_thid = thread_buf_now[x];
    					for(y = 0; y < thread_count_start; y++){
    						if((tmp_thid == thread_buf_start[y]) || (tmp_thid == myThread)){
    							match = 1;
    							y = thread_count_start;
    						}
    					}
    					if(thread_count_start == 0) match = 1;
    					if(match == 0){
    						sceKernelResumeThread(tmp_thid);
    					}
    				}
    			}
    		}
    		paddata_old = paddata.Buttons;
    		sceKernelDelayThread(10000);
    	}
    	return 0;
    }
    
    int module_start (SceSize args, void *argp)
    {
    	SceUID thid;
    
    	thid = sceKernelCreateThread("screenshot", mainThread, 0x18, 0x1000, 0, NULL);
    	if (thid >= 0) sceKernelStartThread(thid, args, argp);
    
    	return 0;
    }
    
    int module_stop (void)
    {
    	return 0;
    }

    Check out my homebrew & C tutorials at http://insomniac.0x89.org/
    Coder formerly known as Insomniac197

    tshirtz: what is irshell ??
    Atarian_: it's where people who work for the IRS go when they die

  24. #8844
    QJ Gamer Bronze
    Points: 6.517, Level: 52
    Level completed: 84%, Points required for next Level: 33
    Overall activity: 0%

    Registriert seit
    Apr 2008
    Ort
    Ireland
    Beiträge
    978
    Points
    6.517
    Level
    52
    Downloads
    0
    Uploads
    0

    Standard

    Dude the spolier thing doesn't work any more its a problem which they need to fix xD

    I think its firefox.

  25. #8845
    Developer
    Points: 7.577, Level: 58
    Level completed: 14%, Points required for next Level: 173
    Overall activity: 0%

    Registriert seit
    Mar 2006
    Beiträge
    1.026
    Points
    7.577
    Level
    58
    Downloads
    0
    Uploads
    0

    Standard

    Works fine for me in Safari and Firefox.

    Check out my homebrew & C tutorials at http://insomniac.0x89.org/
    Coder formerly known as Insomniac197

    tshirtz: what is irshell ??
    Atarian_: it's where people who work for the IRS go when they die

  26. #8846
    QJ Gamer Silver
    Points: 6.763, Level: 54
    Level completed: 7%, Points required for next Level: 187
    Overall activity: 0%

    Registriert seit
    Jul 2006
    Beiträge
    413
    Points
    6.763
    Level
    54
    Downloads
    0
    Uploads
    0

    Standard

    IWN, I tried doing it last night, but instead of freezing the game all it did was shut off the audio and disabled the gamesave menu and some other things.. :/
    Atheist, because I just won't believe in what doesn't show itself to me.

  27. #8847
    Developer
    Points: 7.577, Level: 58
    Level completed: 14%, Points required for next Level: 173
    Overall activity: 0%

    Registriert seit
    Mar 2006
    Beiträge
    1.026
    Points
    7.577
    Level
    58
    Downloads
    0
    Uploads
    0

    Standard

    That code I supplied works.

    It freezes every thread running except it's own.

    Check out my homebrew & C tutorials at http://insomniac.0x89.org/
    Coder formerly known as Insomniac197

    tshirtz: what is irshell ??
    Atarian_: it's where people who work for the IRS go when they die

  28. #8848
    QJ Gamer Bronze
    Points: 6.517, Level: 52
    Level completed: 84%, Points required for next Level: 33
    Overall activity: 0%

    Registriert seit
    Apr 2008
    Ort
    Ireland
    Beiträge
    978
    Points
    6.517
    Level
    52
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von Insert_Witty_Name Beitrag anzeigen
    Works fine for me in Safari and Firefox.
    every other spolier works for me now but yours weard.

  29. #8849
    Avada Kedavra
    Points: 6.813, Level: 54
    Level completed: 32%, Points required for next Level: 137
    Overall activity: 0%

    Registriert seit
    May 2007
    Ort
    Spain
    Beiträge
    703
    Points
    6.813
    Level
    54
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von MiKeY188 Beitrag anzeigen
    every other spolier works for me now but yours weard.
    Yup,same here.

  30. #8850
    QJ Gamer Green
    Points: 4.092, Level: 40
    Level completed: 72%, Points required for next Level: 58
    Overall activity: 0%

    Registriert seit
    Jul 2008
    Beiträge
    508
    Points
    4.092
    Level
    40
    Downloads
    0
    Uploads
    0

    Standard

    How would one remap something (ex. if analog is in desired area[if(pad.Lx < 50) pad.Buttons=pad.Buttons & PSP_CTRL_SQUARE]). At the moment, that does not work, which is why I need some help.


 

Tags for this Thread

Forumregeln

  • Es ist Ihnen nicht erlaubt, neue Themen zu verfassen.
  • Es ist Ihnen nicht erlaubt, auf Beiträge zu antworten.
  • Es ist Ihnen nicht erlaubt, Anhänge hochzuladen.
  • Es ist Ihnen nicht erlaubt, Ihre Beiträge zu bearbeiten.
  •  





Alle Zeitangaben in WEZ -8. Es ist jetzt 09:27 PM Uhr.

Use of this Web site constitutes acceptance of the TERMS & CONDITIONS and PRIVACY POLICY
Copyright © , Caputo Media, LLC. All Rights Reserved. Cluster .