←  Games

ComputerCraft | Programmable Computers for Minecraft

»

MiniatureCraft [New Version, 1.2]

Csstform's Photo Csstform 03 Jul 2014

View PostDetective_Smith, on 02 July 2014 - 10:55 PM, said:

I get some weird errors if I do stuff after doing a Cntrl + T.

I would assume this is due to the use of global variables. All in all tho, this looms like a cool idea, especially the mods and such.
Quote

Antelux's Photo Antelux 03 Jul 2014

View PostCsstform, on 03 July 2014 - 02:28 PM, said:

View PostDetective_Smith, on 02 July 2014 - 10:55 PM, said:

I get some weird errors if I do stuff after doing a Cntrl + T.

I would assume this is due to the use of global variables. All in all tho, this looms like a cool idea, especially the mods and such.

Yea, I figured as much. Hopefully I can get proper exiting in soon. I've already implemented a buffer so far, except not everything on the screen draws. Currently fixing though, and soon enough the game will be playable! (In terms of lag / flickering.)
Quote

TheOddByte's Photo TheOddByte 03 Jul 2014

View PostDetective_Smith, on 03 July 2014 - 04:06 PM, said:

Yea, I figured as much. Hopefully I can get proper exiting in soon. I've already implemented a buffer so far, except not everything on the screen draws. Currently fixing though, and soon enough the game will be playable! (In terms of lag / flickering.)
If you're looking for a way to exit a program then try error
local function exit()
    term.clear()
    term.setCursorPos( 1, 1 )
    print("Thanks for playing!")
    error()
end
This is just a simple example, but it should work ;)
Quote

Antelux's Photo Antelux 03 Jul 2014

View PostTheOddByte, on 03 July 2014 - 07:51 PM, said:

View PostDetective_Smith, on 03 July 2014 - 04:06 PM, said:

Yea, I figured as much. Hopefully I can get proper exiting in soon. I've already implemented a buffer so far, except not everything on the screen draws. Currently fixing though, and soon enough the game will be playable! (In terms of lag / flickering.)
If you're looking for a way to exit a program then try error
local function exit()
	term.clear()
	term.setCursorPos( 1, 1 )
	print("Thanks for playing!")
	error()
end
This is just a simple example, but it should work ;)

Don't worry, I already have some code in mind. I'm not bad at programming, just lazy :P
Quote

TheOddByte's Photo TheOddByte 03 Jul 2014

View PostDetective_Smith, on 03 July 2014 - 08:02 PM, said:

Don't worry, I already have some code in mind. I'm not bad at programming, just lazy :P
Haha okay, But that's usually the best way to exit a program :P ( IMO )
Quote

Antelux's Photo Antelux 18 Jul 2014

Made the buffer run (alot) faster, the game should be more stable now. More details in the main post.
Quote

Saldor010's Photo Saldor010 18 Jul 2014

Still very laggy for me, but I'm sure it will get better over time. Atleast it's playable now ;)
Quote

Antelux's Photo Antelux 23 Jul 2014

Update 1.2. Is out, with a bunch of new.... menus! More info in the main post.
Quote

TheOddByte's Photo TheOddByte 23 Jul 2014

Does the game run faster in the new version? I see that it's atleast playable now( from the comment above yours )
And how far from completion is the server script?
Quote

Antelux's Photo Antelux 24 Jul 2014

Its... getting there. I cant actually send the map over rednet, because it contains recursive entries. However, I found a solution that may stop users from having to download anything server related, like custom assets and such. This would probably increase security. As for the games speed, I have been having some problems with the buffer. I've tried to implement a feature to only draw what changes on the screen, and it hasn't gone too well.
Edited by Detective_Smith, 24 July 2014 - 12:32 AM.
Quote

TheOddByte's Photo TheOddByte 24 Jul 2014

View PostDetective_Smith, on 24 July 2014 - 12:31 AM, said:

Its... getting there. I cant actually send the map over rednet, because it contains recursive entries. However, I found a solution that may stop users from having to download anything server related, like custom assets and such. This would probably increase security. As for the games speed, I have been having some problems with the buffer. I've tried to implement a feature to only draw what changes on the screen, and it hasn't gone too well.
I hope you're having the buffer as the top priority right now, because having the game running smooth before doing multiplayer is better :P
Quote

Antelux's Photo Antelux 25 Jul 2014

View PostTheOddByte, on 24 July 2014 - 09:51 PM, said:

I hope you're having the buffer as the top priority right now, because having the game running smooth before doing multiplayer is better :P
Yea, I agree. I'm looking into faster methods. Of course, there are other ways to make faster buffers, but I specifically want mine to be a redirect one. It simplifys alot of things. Hopefully I can get the buffer to draw the changes only sometime soon. It can be a real turnoff for others if they cant play decently.
Quote

YoYoYonnY's Photo YoYoYonnY 11 Oct 2014

I think the APIs are a bit of a overkill. They might slow your game down and they might delay the rendering. At the very least, you should use a rendering method in the main game program, like this:
for x=1,w do
  for y=1,h do
    term.setCursorPos(x,y)
    term.setBackgroundColor(map[x][y].bc)
    term.setTextColor(map[x][y].tc)
    term.write(map[x][y].char)
  end
end
Quote

TheOddByte's Photo TheOddByte 12 Oct 2014

View PostYoYoYonnY, on 11 October 2014 - 08:03 PM, said:

...
The problem with that code is that it would flicker alot without at proper buffer.
Quote

YoYoYonnY's Photo YoYoYonnY 16 Oct 2014

View PostTheOddByte, on 12 October 2014 - 04:16 PM, said:

View PostYoYoYonnY, on 11 October 2014 - 08:03 PM, said:

...
The problem with that code is that it would flicker alot without at proper buffer.
Thats why I posted this exact code. It doesnt have the term.clear(), so the screen wont flicker. Acturely, if you redraw the same stuff you did before, you wont even notice the redraw.
Edit: I just made a term.redraw() function to redraw the screen only when I need to
for n=0,15 do
    term.setBackgroundColor(2^n)
    term.clear()
    term.redraw()
    -- Flicker the screen with all the different colors
end
for n=0,15 do
    term.setBackgroundColor(2^n)
    term.clear()
end
term.redraw()
-- Make the screen black (No flickering)

Edited by YoYoYonnY, 16 October 2014 - 10:35 PM.
Quote

CoLDarkness's Photo CoLDarkness 17 Oct 2014

Great work. Really interesting.
Quote

AssossaGPB's Photo AssossaGPB 17 Oct 2014

Nice Smith, can't believe how complex that is :D
Quote

Saldor010's Photo Saldor010 17 Oct 2014

Decided to check this game again, and see if it was any better when it came to lag.
..
IT IS!

It's about 3 times better than it was when it first released, and is now actually playable for people like me who do vanilla Computercraft!

Awesome job man!
Quote

Antelux's Photo Antelux 17 Oct 2014

Hmm. Didn't know this thread was still alive. Might as well tell you whats with it so far.

Basically, I did finish up a "working" buffer than only uses strings instead of tables, making it less of a memory hog, and allows for better rednet compatibility. I stopped awhile ago on the progress, but I don't remember why.

I might restart working on the game again. If I do, ill most likely rewrite it from the ground up, because I'm like that :P
Though, I would use some of the API's already available. It would mostly just be for cleaner code. Anyway, its cool to see people still playing my game, so thanks!
Quote

Antelux's Photo Antelux 21 Dec 2014

Guess what. MiniatureCraft isn't dead.

MiniatureCraft 2.0
Quote