This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
powerboat9's profile picture

BGUIFC: A Graphics Library

Started by powerboat9, 25 November 2015 - 03:36 AM
powerboat9 #1
Posted 25 November 2015 - 04:36 AM
I have just started work on this library, so there isn't a lot of code.

All intelligent feedback is appreciated.

It has an installer now!
Edited on 27 November 2015 - 01:35 AM
Creator #2
Posted 25 November 2015 - 06:00 AM
A pastebin and screenies would be appreciated.
Awe2K #3
Posted 25 November 2015 - 08:56 AM
Hi. What does your graphics library do (maybe some readme/documentation)?
Yeah, have a good luck with development :)/>
Waitdev_ #4
Posted 25 November 2015 - 10:39 AM
looks cool from the code, this could have some big possibilities :D/>
also, the "layers" thing is a really cool idea ;)/> might try making an API, but its your choice if you want me to put it on the forums or not. it was your idea ;)/>
powerboat9 #5
Posted 26 November 2015 - 02:57 PM
looks cool from the code, this could have some big possibilities :D/>/>
also, the "layers" thing is a really cool idea ;)/>/> might try making an API, but its your choice if you want me to put it on the forums or not. it was your idea ;)/>/>

I'd rather you don't, but thanks for asking.
powerboat9 #6
Posted 26 November 2015 - 03:17 PM
Just got hexToNumber working:

My Documentation, README.md said:
hexToNumber(string) - Turns a string in hexadecimal into a base-10 number."
Edited on 26 November 2015 - 04:02 PM
powerboat9 #7
Posted 26 November 2015 - 04:59 PM
Got a lot finished:

My Documentation, README.md said:
getScreen(terminal object, layers) - Creates a screen object with a certain amount of layers.

screen:writeChar(layer, character to write, color of the character, background color for the character).

screen:clearLine(layer, line to clear) - Clears a line.

screen:clear(layer) - Clears a layer.

screen:clearLayerRange(first layer to clear, last layer to clear) - Clears a range of layers.

screen:scroll(layer) - Scrolls the layer.

screen:blit(layer, text to write, text color, background color of text) - Writes text to layer.

Please note that the color is a value between 1 and 16, inclusive. You can't use the color api.
LeDark Lua #8
Posted 26 November 2015 - 05:35 PM
power you can use hex charachters like:

term.setTextColor(0x1) //White
term.setBackgroundColor(0x4000) //Black

and good luck with the project!
powerboat9 #9
Posted 27 November 2015 - 01:54 AM
power you can use hex charachters like:

term.setTextColor(0x1) //White
term.setBackgroundColor(0x4000) //Black

and good luck with the project!

This looks like a good idea, can you elaborate?
powerboat9 #10
Posted 27 November 2015 - 02:33 AM
Now this has an installer!

Just type in after downloading the installer:
Spoilerdownloader.lua powerboat9 BGUIFC
LeDark Lua #11
Posted 27 November 2015 - 07:34 AM
power you can use hex charachters like:

term.setTextColor(0x1) //White
term.setBackgroundColor(0x4000) //Black

and good luck with the project!

This looks like a good idea, can you elaborate?
I meant try to write these values in the term and it will set to that color