D
Is there some sort of wait command?
Like the one in lpp-vita?
If not, would you help me figure out how to make a wait function?
Is there some sort of wait command?
Like the one in lpp-vita?
If not, would you help me figure out how to make a wait function?
function System.wait(milliseconds)
tmp = Timer.new()
while Timer.getTime(tmp) < milliseconds do end
Timer.destroy(tmp)
end
You can use a Timer to temporary block your thread. (Remember to purge the Timer object and take in mind that Timer uses milliseconds, System.wait in lpp-vita uses microseconds).
--------------------- MERGED ---------------------------
This, for example, is a System.wait implementation for lpp-3ds:
Code:function System.wait(milliseconds) tmp = Timer.new() while Timer.getTime(tmp) < milliseconds do end Timer.destroy(tmp) end
Doesn't this cause a useless loop (wasting battery)? What if I wanted a thread to wait like 10 minutes?
How do I distribute a homebrew as .cia? Should I compile the source with index.lua on its folder? I have no kernel hax so I can't even experiment myself.
Oh, I see. Is there some sort of convention on how to name/where to put the script, or should I do whatever I want?You can compile the elf provided in the R3 build with your own banner and icon (but it will use index.lua from root of SD card so it's not very good) or you can compile from sources your own build which loads a custom script by editing main.cpp( https://github.com/Rinnegatamante/lpp-3ds/blob/master/source/main.cpp#L85-L88 )
Oh, I see. Is there some sort of convention on how to name/where to put the script, or should I do whatever I want?
Put index.lua in the same directory as the 3dsxHow i use this? I got only Black Screen there missing something.
I use OFW10.1.0-27EU Ironfall
Thanks now works but i got my 3ds now bricked because i used the Cia Manager i tought A button was launch but he delete it.Put index.lua in the same directory as the 3dsx
The draw rotated image on the GPU, the documentation says radius, but no angle input? How could a radius be helpful? With no angle to base rotation on.
Radius is the distance from the outside of a circle to the inside.0, 0 is the angle used for rotation. I'll probably add another function to rotate an image using the center as rotation angle.
Radius is the distance from the outside of a circle to the inside.
void Sound.play(wav_id wav_file, int loop, u32 channel, [u32 channel2])
Sorry to be a noob, but where can I find the u32 channel of my wav file?