Homebrew Homebrew Development

CalebW

Fellow Temper
Member
Joined
Jun 29, 2012
Messages
638
Trophies
0
Location
Texas
XP
545
Country
United States
I solved the RAND_MAX variable error by adding
Code:
#include
at the top of background.c. I don't know if this was the right way to do this, but it worked... My ctrulib is the latest version(installed from git) but I don't have a CTRULIB environmental variable set(unless it does so in the Makefile when installing, but that's unlikely)
 
  • Like
Reactions: Margen67

shinyquagsire23

SALT/Sm4sh Leak Guy
Member
Joined
Nov 18, 2012
Messages
1,977
Trophies
2
Age
26
Location
Las Vegas
XP
3,765
Country
United States
I solved the RAND_MAX variable error by adding
Code:
#include
at the top of background.c. I don't know if this was the right way to do this, but it worked... My ctrulib is the latest version(installed from git) but I don't have a CTRULIB environmental variable set(unless it does so in the Makefile when installing, but that's unlikely)

It might have been the new gcc update, which seems to have broken a few things. I was compiling GameYob and I had to put a #include <stdlib.h> in config.cpp and inputhelper.cpp. It compiles now, which is awesome because apparently it was broke a while back.
 

ichichfly

Well-Known Member
Member
Joined
Sep 23, 2009
Messages
619
Trophies
1
XP
1,076
Country
Gambia, The
Quick question, how do I configure SD support for 3dmoo?
you have to start 3dmoo with cmd args the first one is always the file path the following can be
-sdmc <path> //sets the path to the sdmc <there is a default path and the SD is access-able but the detect function returns no SD>
-sdwrite //if this is set the SD writable will return true the SD is write able even if this is not set
-d //disassemble log
-noscreen //self explaining
-codepatch <.code file> //replace the code in the NCCH you are running
-sysdata <path> //path to a folder with sysdata (dumped from NAND)-slotone //returns true if the app ask if there is a slot one card
-configsave //loads the cfg from the config file in the sysdat
-gdbport <port> //only works if the compiled with GDB_STUB sets the port for a gdb debugger to attach to 3dmoo (C::B,insight,...)
 
  • Like
Reactions: filfat

jasonmbrown

Well-Known Member
Newcomer
Joined
Sep 11, 2010
Messages
47
Trophies
0
XP
183
Country
Canada
Someone wanna take a quick look at my source and tell me why weird things are happening?

Still trying to recreate space invaders, from scratch on the 3ds. Currently I have it drawing the invaders and I manually put in the Move right and move left. However when I press Right to move them Right, They move Left, and vice versa. It also seems they are being drawn in an Upside Down order (If I press Left Enough They Will Bump Up a line... When it should be pressing right causes them to bump down, *Havent added the Line Movement Functions yet but due to a bug that wont matter later,when pressing dpad it doesnt run the function to check If its safe to move them left or right, it just runs the move code*

Also I Thought I had done the Drawing Correctly But If I put in 2 into the array containing the alien layout, which should represent the 2nd alien sprite (havent added it yet) it puts out invader/alien 1's 2nd animation (for first animation) and a green square (for 2nd animation (0 is = to draw pixel) so the square makes sense). Its the First thing Ive ever made in c++ so any tips or comments would be appreciated. Also Anyone willing to take a look at it and see where I derped since the documentation on the 3ds isnt great and its kinda annoying to create text output to display debug info (although I might create a header file that I can use to draw words to the bottom screen specifically to check the values of my array's and variables).

I uploaded the source of what I have currently below, its project file is in codeblocks. But Most of the Functions are in draw.c, the 3dsx file is in the zip as well.

*Its more updated then the last one I posted However*
 

Attachments

  • HelloWorld.zip
    95.9 KB · Views: 236

minexew

ayy lmao
Member
Joined
Mar 16, 2013
Messages
228
Trophies
0
XP
284
Country
ctrGL can now detect when the GPU or one of the related DMA controllers stops responding.
This is not incredibly useful if the GPU actually hangs, because even if you quit the application, the POS PICA will stay stuck until a system restart so no other GPU-enabled homebrew will work. (and I'm not aware of any software way to reset the GPU)
However, it seems that sometimes the relevant events simply don't get signaled - I have no idea what's going on, it happens more quickly in more complex scenes and sometimes it's the PPF event that doesn't signal, rather than P3D. I found absolutely no pattern in this, the intervals seem to be between 60 and 300 seconds.
Either way, when this happens, everything will actually work just fine again in the next frame if you properly set a timeout for the event wait.

Weird
as
fuck.
 

minexew

ayy lmao
Member
Joined
Mar 16, 2013
Messages
228
Trophies
0
XP
284
Country
luaJIT confirmed
(admittedly without the jit)

X9hEmn0.png
 

shinyquagsire23

SALT/Sm4sh Leak Guy
Member
Joined
Nov 18, 2012
Messages
1,977
Trophies
2
Age
26
Location
Las Vegas
XP
3,765
Country
United States
Is there a max file size for .3dsx files? I'm making an attempt to port gpSP to the 3DS, and while I have everything in line for it to at least be executed (main loop is completely isolated from the rest of the program at the moment), the ending file size is 1.1MB and it seems to crash if I run it. However, if I don't link all the other files it will run just fine. I'm not entirely sure what's causing the file size to go up so much but it's preventing me from getting at least *something* running.
 

minexew

ayy lmao
Member
Joined
Mar 16, 2013
Messages
228
Trophies
0
XP
284
Country
Is there a max file size for .3dsx files? I'm making an attempt to port gpSP to the 3DS, and while I have everything in line for it to at least be executed (main loop is completely isolated from the rest of the program at the moment), the ending file size is 1.1MB and it seems to crash if I run it. However, if I don't link all the other files it will run just fine. I'm not entirely sure what's causing the file size to go up so much but it's preventing me from getting at least *something* running.

At first, my ELF file was about 2.5 megs and 3dsx completely refused to process it. I found that using gc-sections is an absolute must for any half-serious 3ds development.
If the huge binary isn't the reason for your issues (I'm currently at ~770 KiB and working fine), you'll probably have to do the good old line-by-line debugging.
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
    Veho @ Veho: Has he had seizures before?