Homebrew [W.i.P.] RPG Maker 3DS

  • Thread starter Thread starter Rinnegatamante
  • Start date Start date
  • Views Views 57,322
  • Replies Replies 193
  • Likes Likes 48
You could check this one: https://forums.coronalabs.com/topic/40443-mode-7-demo-full-source/
it seems that this is a "example" which contains a whole mode7-setup written in LUA.

Have uploaded the file archive for you so you don't need to register there:
http://www.file-upload.net/download-10848303/Mode_7.zip.html


1) I load the level and create the sprites.

2) I draw the entire level and place it into a display group.

3) That group gets placed into a snapshot.

4) I rotate the group and snapshot to match the player movement.

5) I invalidate() the snapshot and then distort it to give a perspective effect.

This code surely works on a PC.
Launching a code like this and doing the same things on a 3DS for EVERY FRAME will cause a massively framedrop.
If you enable also native 3D and so duplicate frames on the screen, your game will be totally unplayable.
 
This code surely works on a PC.
Launching a code like this and doing the same things on a 3DS for EVERY FRAME will cause a massively framedrop.
If you enable also native 3D and so duplicate frames on the screen, your game will be totally unplayable.
yea, I know. As I said: This is just a example which shows how it COULD work on the 3DS.
I've never said to use this example 1:1 :D
 
Finished the pause menu with gold and time played features, characters blinding with heoes basic info and menu.

menu_rpg.bmp
 
Awesome!! :)
Do you know if we will be able to tweak it? I know this is the concept and it's great, I just think that this could be enhanced with more graphical stuff.
 
Awesome!! :)
Do you know if we will be able to tweak it? I know this is the concept and it's great, I just think that this could be enhanced with more graphical stuff.

Of course, it will be fully customizable (for example sostituting chars with facesets, adding info, voices and so on).
 
  • Like
Reactions: Fatalanus
oh, man.
Just a big hank you.:wub:

You'll obviously have to know a bit of LUA. The graphic part of the menu for example is done by this code:
Code:
function RenderPauseMenu()
   y = 3
   max_y = 20 * #pause_voices
   -- Main Menu
   Screen.fillEmptyRect(0 , 100, 0, 2 + max_y, white, BOTTOM_SCREEN)
   Screen.fillRect(1 , 99, 0, 1 + max_y, window, BOTTOM_SCREEN)
   for i, voice in pairs(pause_voices) do
     if i == pause_i then
       Screen.fillRect(1, 99, 1 + 20 * (i - 1),  1 + 20 * i, Color.new(0, 128, 255), BOTTOM_SCREEN)
       Font.print(def_font, 3, y, voice, Color.new(255,255,0), BOTTOM_SCREEN)
     else
       Font.print(def_font, 3, y, voice, white, BOTTOM_SCREEN)
     end
     y = y + 20
   end
   
   -- Info Window
   Screen.fillEmptyRect(0 , 100, 2 + max_y, 239, white, BOTTOM_SCREEN)
   Screen.fillRect(1 , 99, 3 + max_y, 238, window, BOTTOM_SCREEN)
   Font.print(def_font, 33, 5 + max_y, "Gold", Color.new(255,255,0), BOTTOM_SCREEN)
   Font.print(def_font, 8, 25 + max_y, gold, white, BOTTOM_SCREEN)
   Font.print(def_font, 32, 65 + max_y, "Time", Color.new(255,255,0), BOTTOM_SCREEN)
   Font.print(def_font, 8, 85 + max_y, FormatTime(Timer.getTime(game_time) / 1000), white, BOTTOM_SCREEN)
   
   -- Characters Window
   Screen.fillEmptyRect(100 , 319, 0, 239, white, BOTTOM_SCREEN)
   Screen.fillRect(101 , 318, 1, 238, window, BOTTOM_SCREEN)
   char_y = 15
   for i, chara in pairs(party) do
     Font.print(def_font, 115, char_y - 10, chara, Color.new(255,255,0), BOTTOM_SCREEN)
     Font.print(def_font, 210, char_y - 10, "Lv. " .. party_stats[i].level, white, BOTTOM_SCREEN)
     Font.setPixelSizes(def_font,14)
     if (100 * ((party_stats[i].hp_max - party_stats[i].hp) / party_stats[i].hp_max)) >= 85 then
       Font.print(def_font, 110, char_y + 5, "HP: " .. party_stats[i].hp .. " / " .. party_stats[i].hp_max , Color.new(255,0,0), BOTTOM_SCREEN)
     elseif (100 * ((party_stats[i].hp_max - party_stats[i].hp) / party_stats[i].hp_max)) >= 60 then
       Font.print(def_font, 110, char_y + 5, "HP: " .. party_stats[i].hp .. " / " .. party_stats[i].hp_max , Color.new(255,255,0), BOTTOM_SCREEN)
     else
       Font.print(def_font, 110, char_y + 5, "HP: " .. party_stats[i].hp .. " / " .. party_stats[i].hp_max , white, BOTTOM_SCREEN)
     end
     Font.print(def_font, 210, char_y + 5, "MP: " .. party_stats[i].mp .. " / " .. party_stats[i].mp_max , white, BOTTOM_SCREEN)
     Font.print(def_font, 110, char_y + 20, "EXP: " .. party_stats[i].exp .. " / " .. party_stats[i].exp_to_level , white, BOTTOM_SCREEN)
     Screen.drawPartialImage(280, char_y, hero_width, hero_height, hero_width, hero_height , raw_party_chars[i], BOTTOM_SCREEN)
     char_y = char_y + 59
     Font.setPixelSizes(def_font,16)
   end
end
 
Ah, my bad. I was thinking it was custom .png that we could add in the background, borders for example.
A little bit like the character sprites. :)

Indeed I'll have to take the time to learn I guess. xD
 
You'll obviously have to know a bit of LUA. The graphic part of the menu for example is done by this code:
Code:
function RenderPauseMenu()
   y = 3
   max_y = 20 * #pause_voices
   -- Main Menu
   Screen.fillEmptyRect(0 , 100, 0, 2 + max_y, white, BOTTOM_SCREEN)
   Screen.fillRect(1 , 99, 0, 1 + max_y, window, BOTTOM_SCREEN)
   for i, voice in pairs(pause_voices) do
     if i == pause_i then
       Screen.fillRect(1, 99, 1 + 20 * (i - 1),  1 + 20 * i, Color.new(0, 128, 255), BOTTOM_SCREEN)
       Font.print(def_font, 3, y, voice, Color.new(255,255,0), BOTTOM_SCREEN)
     else
       Font.print(def_font, 3, y, voice, white, BOTTOM_SCREEN)
     end
     y = y + 20
   end
   
   -- Info Window
   Screen.fillEmptyRect(0 , 100, 2 + max_y, 239, white, BOTTOM_SCREEN)
   Screen.fillRect(1 , 99, 3 + max_y, 238, window, BOTTOM_SCREEN)
   Font.print(def_font, 33, 5 + max_y, "Gold", Color.new(255,255,0), BOTTOM_SCREEN)
   Font.print(def_font, 8, 25 + max_y, gold, white, BOTTOM_SCREEN)
   Font.print(def_font, 32, 65 + max_y, "Time", Color.new(255,255,0), BOTTOM_SCREEN)
   Font.print(def_font, 8, 85 + max_y, FormatTime(Timer.getTime(game_time) / 1000), white, BOTTOM_SCREEN)
   
   -- Characters Window
   Screen.fillEmptyRect(100 , 319, 0, 239, white, BOTTOM_SCREEN)
   Screen.fillRect(101 , 318, 1, 238, window, BOTTOM_SCREEN)
   char_y = 15
   for i, chara in pairs(party) do
     Font.print(def_font, 115, char_y - 10, chara, Color.new(255,255,0), BOTTOM_SCREEN)
     Font.print(def_font, 210, char_y - 10, "Lv. " .. party_stats[i].level, white, BOTTOM_SCREEN)
     Font.setPixelSizes(def_font,14)
     if (100 * ((party_stats[i].hp_max - party_stats[i].hp) / party_stats[i].hp_max)) >= 85 then
       Font.print(def_font, 110, char_y + 5, "HP: " .. party_stats[i].hp .. " / " .. party_stats[i].hp_max , Color.new(255,0,0), BOTTOM_SCREEN)
     elseif (100 * ((party_stats[i].hp_max - party_stats[i].hp) / party_stats[i].hp_max)) >= 60 then
       Font.print(def_font, 110, char_y + 5, "HP: " .. party_stats[i].hp .. " / " .. party_stats[i].hp_max , Color.new(255,255,0), BOTTOM_SCREEN)
     else
       Font.print(def_font, 110, char_y + 5, "HP: " .. party_stats[i].hp .. " / " .. party_stats[i].hp_max , white, BOTTOM_SCREEN)
     end
     Font.print(def_font, 210, char_y + 5, "MP: " .. party_stats[i].mp .. " / " .. party_stats[i].mp_max , white, BOTTOM_SCREEN)
     Font.print(def_font, 110, char_y + 20, "EXP: " .. party_stats[i].exp .. " / " .. party_stats[i].exp_to_level , white, BOTTOM_SCREEN)
     Screen.drawPartialImage(280, char_y, hero_width, hero_height, hero_width, hero_height , raw_party_chars[i], BOTTOM_SCREEN)
     char_y = char_y + 59
     Font.setPixelSizes(def_font,16)
   end
end
It looks very easy o:
Normally I never worked with Lua, only with C# + Unity.
But this is very easy to understand :D Good to know :)
 
wow, it seems easy to use! I like this video about level editor!
Do we have a limit about the map size?
 
Ok. And i guess that you already speak about multiple small maps that do 1 big map at the end, right?
 

Site & Scene News

Popular threads in this forum