Let's make a 3DS homebrew together

Kingy

Well-Known Member
OP
Member
Joined
Feb 21, 2016
Messages
949
Trophies
1
Location
England I guess
XP
2,927
Country
United Kingdom
So, the title.

I was really bored so I thought of this.

Just post some code and I'll add it to the homebrew. Tell me which line, etc.

The code at the moment:

Code:
#include <string.h>
#include <3ds.h>
#include <stdio.h>

void cls() {
    printf("\e[1;1H\e[2J");
}
int main()
{
    gfxInitDefault();
    //gfxSet3D(true); //Uncomment if using stereoscopic 3D
    consoleInit(GFX_TOP, NULL); //Change this line to consoleInit(GFX_BOTTOM, NULL) if using the bottom screen.

   printf("Welcome to The Edge of the 3DS! The best homebrew ever!\n\n\n");
   printf("Press A to begin your lovely experience. :^)");



    // Main loop
    while (aptMainLoop())
    {
        gspWaitForVBlank();
        hidScanInput();

    
   u32 kDown = hidKeysDown();
   if (kDown & KEY_A){
   cls();
    printf("Swiftloke was here\n");
    printf("smileyhead said: Oh boi, this gunna be good :creep:\n\n Code:\n del ""\n");
    printf("snowdori is gay and no one like hiim :^)\n");
    printf("delet 300 app limit pls thank you\n");
    }
     
        if (kDown & KEY_START)
            break; //Break in order to return to hbmenu

        // Flush and swap frame-buffers
        gfxFlushBuffers();
        gfxSwapBuffers();
    }

    gfxExit();
    return 0;
}
Yeah, It'll be fun.

Cya.
 
Last edited by Kingy,
D

Deleted User

Guest
Code:
#include <string.h>
#include <stdio.h>
#include <3ds.h>
#include <sf2d.h>
#include <sfil.h>

#include "stick_magician_png.h"

int main(){
     gfxInitDefault();
     //gfxSet3D(true); //Uncomment if using stereoscopic 3D
     consoleInit(GFX_TOP, NULL); //Change this line to consoleInit(GFX_BOTTOM, NULL) if using the bottom screen.

    // Initialize services
    sf2d_init();
    sf2d_texture *SMag = sfil_load_PNG_buffer(stick_magician_png, SF2D_PLACE_RAM);

    printf("Swiftloke was here\n");

    // Main loop
    while (aptMainLoop()) {
         gspWaitForVBlank();
         hidScanInput();

         //code

         u32 kDown = hidKeysDown();
         if(kDown & KEY_START) break; //Break in order to return to hbmenu

       
         // Draw image
         sf2d_start_frame(GFX_TOP, GFX_LEFT);
         sf2d_draw_texture(160, 120);
         sf2d_end_frame();

         sf2d_swapbuffers();

         // Flush and swap frame-buffers
         gfxFlushBuffers();
         gfxSwapBuffers();
    }
    gfxExit();
    return0;
}

Legitimate enough, I would imagine...
 

Kingy

Well-Known Member
OP
Member
Joined
Feb 21, 2016
Messages
949
Trophies
1
Location
England I guess
XP
2,927
Country
United Kingdom
We need a name. I have an icon:
upload_2016-8-10_14-43-18.png
 
D

Deleted User

Guest
*COUGH* *COUGH*
Has my commit not been pushed to the OP yet? :'O

Any code conflicts? Would you like a sample image to go with that commit? ;O;
 

Swiftloke

Hwaaaa!
Member
Joined
Jan 26, 2015
Messages
1,770
Trophies
0
Location
Nowhere
XP
1,334
Country
United States
Code:
#include <string.h>
#include <stdio.h>
#include <3ds.h>
#include <sf2d.h>
#include <sfil.h>

#include "stick_magician_png.h"

int main(){
     gfxInitDefault();
     //gfxSet3D(true); //Uncomment if using stereoscopic 3D
     consoleInit(GFX_TOP, NULL); //Change this line to consoleInit(GFX_BOTTOM, NULL) if using the bottom screen.

    // Initialize services
    sf2d_init();
    sf2d_texture *SMag = sfil_load_PNG_buffer(stick_magician_png, SF2D_PLACE_RAM);

    printf("Swiftloke was here\n");

    // Main loop
    while (aptMainLoop()) {
         gspWaitForVBlank();
         hidScanInput();

         //code

         u32 kDown = hidKeysDown();
         if(kDown & KEY_START) break; //Break in order to return to hbmenu

      
         // Draw image
         sf2d_start_frame(GFX_TOP, GFX_LEFT);
         sf2d_draw_texture(160, 120);
         sf2d_end_frame();

         sf2d_swapbuffers();

         // Flush and swap frame-buffers
         gfxFlushBuffers();
         gfxSwapBuffers();
    }
    gfxExit();
    return0;
}

Legitimate enough, I would imagine...
So, you know C++? Once I'm done with my C++ Win32 console course, do you know where I should go from there?
 
General chit-chat
Help Users
  • No one is chatting at the moment.
    KenniesNewName @ KenniesNewName: From his auntie's wife side