Thursday, 08 January 2009
 
  Home arrow Forum  
Main Menu
Home
News
Forum
Documentation
Download
Links
Administrator
Login Form
Welcome, Guest. Please login or register.
January 08, 2009, 12:25:51 PM
Username: Password:
Login with username, password and session length

Forgot your password?
Recent Posts
DSLua Community
Welcome, Guest. Please login or register.
January 08, 2009, 12:25:51 PM
1724 Posts in 316 Topics by 10288 Members
Latest Member: BectAutonnano
Pages: 1 ... 8 9 [10]
 91 
 on: November 07, 2007, 04:04:26 AM 
Started by sylus101 - Last post by admin
Sorry to hear that.  But, best of luck with your new projects!  And, thanks for the help on DSLua!

 92 
 on: November 07, 2007, 02:31:27 AM 
Started by sylus101 - Last post by sylus101
After struggling for too long with some of DSLua's limitations, specifically with sprite manipulation, I've decided to move my current project to PALib and learn a little C in the process. Shorter frames due to easy flipping of Sprites, simple animations and much more...

I LOVE Lua. It's simple and elegant. C is clunky and confusing.... but PALib provides such dramatic differences in what you can do that it was a needed change.

Wish me luck, and keep DSLua alive. It was the best stepping stone an aspiring game coder could ask for. I'll be checking back, hoping for some new changes as I'd happily return to LUA if certain advancements appear.

Sylus

 93 
 on: November 02, 2007, 02:40:58 PM 
Started by daltonlaffs - Last post by asiekierka
I kill daltonlaffs with a bad-written, buggy DSLua piece of code.

 94 
 on: November 02, 2007, 01:28:05 PM 
Started by asiekierka - Last post by asiekierka
ldr_f = BGBotMap:GetTile(11,8)
ldr_h = BGBotMap:GetTile(12,8)
ldr_n = BGBotMap:GetTile(13,8)


BGBotMap is a tiled map.
That part gives me the error "loop in gettable stack traceback". Does anybody know a solution? Or should i post more of the code?

 95 
 on: October 29, 2007, 05:51:37 PM 
Started by nini324 - Last post by Alexand3rS
this post is in the wrong section...  Roll Eyes just sayin... Grin

 96 
 on: October 29, 2007, 05:47:51 PM 
Started by retman - Last post by Alexand3rS
I just got told DSLua does not WORK ON A SLOT-1 DEVICE!

 Shocked Shocked Shocked Shocked Shocked

Slot-1 devices are the most popular things in ds homebrew right now and DSLua doesn't work with them?

this is disgraceful.

slot-1 devices have been out for ages, i'm guessing so has DSLua why the hell has it took so long to get a update for slot-1 device users.

and may i ask when will it work with slot-1 devices? i use a r4ds - the best slot 1 device on the market.

And just think about it - i was going to start learning Lua so i can make a game for the ds. NOW I CANT! because
DSLua doesn't not work on a slot one device.


kkthxbai

man... chill... don't get your panties all in a bunch!

 97 
 on: October 27, 2007, 03:37:43 PM 
Started by Alexand3rS - Last post by Alexand3rS
Hi I am new to DSlua and I was wondering how to move a sprite (character picture) with the D pad around the screen...  Huh

 98 
 on: October 25, 2007, 01:45:24 PM 
Started by sylus101 - Last post by sylus101
Forgive the double post, but to further the idea, here's a way you might utilize this (as I've done more testing and it works very well...) without having to remember what the frame was a sprite was created on. It'll eat up memory with one more variable, but hey... what's one more in the grand scheme of things?

Before creating your sprite, set your variable to the frame you're about to use.
Code:
spritecreateframe = 3
sprite = Sprite.Create(spriteframe,spritecreateframe,0,100,100)

When that sprite needs to be freed, just set the frame back to where it was created beforehand, without going through your script to find what frame it was created on:
Code:
sprite:SetFrame(spriteframe,spritecreateframe)
sprite:Free()

 99 
 on: October 25, 2007, 01:34:11 PM 
Started by nonchip - Last post by nonchip
thanks, but i think the DnD-method I use is a cool demonstration of the DSLua functions.

 100 
 on: October 22, 2007, 03:18:46 PM 
Started by nonchip - Last post by daltonlaffs
Resetting coordinates is next to impossible, but there is a solution to this problem: The Stylus.Down() function.

Here's a fixed version of your code:

Code:
require("functions.inc.lua")
SCREEN_TOP    = 1
SCREEN_BOTTOM = 0
BGTopText = Screen.LoadTextBG()
BGBotText = Screen.LoadTextBG()
Screen.Initialize( SCREEN_TOP,    BGTopText )
Screen.Initialize( SCREEN_BOTTOM, BGBotText )

BGTopText:PrintXY( 1, 5, "Hi "..DSLua.UserName().."!" )
BGTopText:PrintXY( 3, 5, "Welcome to SKETCH" )
while Pads.Start() == false do
    BGBotText:PrintXY(1,2,"Click for Keyboard-Mode")
    BGBotText:PrintXY(1,5,"Click for Stylus-Mode")
    BGBotText:PrintXY(1,8,"Click for Stylus-Line-Mode")
    while true do
        DSLua.LidCloseAction()
if Stylus.Down() then
        if stylusInTextBox(1, 1, 5, 3) then
            DSLua.WaitForNoKey()
            BGBotText:Clear()
            dofile("sketch_keyboard.lua")
            break
        end
        if stylusInTextBox(1, 4, 5, 6) then
            DSLua.WaitForNoStylus()
            BGBotText:Clear()
            dofile("sketch_stylus_free.lua")
            break
        end
        if stylusInTextBox(1, 7, 5, 9) then
            DSLua.WaitForNoStylus()
            BGBotText:Clear()
            dofile("sketch_stylus_lines.lua")
            break
        end
    end
end
end

The simple addition was to check whether the Stylus is on the screen or not. If not, the stylusInBox commands aren't even run, so the old coordinates are not processed.

Pages: 1 ... 8 9 [10]


(C) 2009 DSLua

DSLua - Best scripting language for Nintendo DS home-brew!