Jump to content


KingofGamesYami's Content

There have been 51 items by KingofGamesYami (Search limited from 10-February 22)


By content type

See this member's


Sort by                Order  

#278137 The ban game

Posted by KingofGamesYami on 18 August 2018 - 11:13 PM in Forum Games

Banned for causing ghandi nukes.

Pokemon



#277837 Reading bytes

Posted by KingofGamesYami on 20 July 2018 - 12:52 AM in Ask a Pro

I have very little experience with reading binary in CC, but my first thought is that num is larger than the number of bytes available for some reason.



#277873 Reading bytes

Posted by KingofGamesYami on 23 July 2018 - 11:57 PM in Ask a Pro

This is why you're getting that error.



#277834 Reading bytes

Posted by KingofGamesYami on 19 July 2018 - 09:56 PM in Ask a Pro

HTTP binary support was a long standing bug that was patched in 1.80pr1. If you are using an older version it will not work.



#277879 Reading bytes

Posted by KingofGamesYami on 24 July 2018 - 09:34 PM in Ask a Pro

unpack has been renamed to table.unpack in later versions.



#278091 computercrafts terminal

Posted by KingofGamesYami on 12 August 2018 - 03:25 PM in Ask a Pro

View PostTa©ti_Tac0Z, on 12 August 2018 - 01:16 PM, said:


View PostBomb Bloke, on 11 August 2018 - 02:37 PM, said:

colours.orange doesn't actually hold a representation of the colour orange, for example - it merely holds a palette index.


wrong...:
Posted Image

the organges rgb color value is 2 (EDIT: not just the color index) as stated in the table: http://computercraft...ki/Colors_(API)


You are mistaken. "2" is not an RGB value.

ComputerCraft uses binary indexes (2^0,2^1,2^2 ... 2^15). This is primarily to support passing multiple colors as one number to bundled cables. For example, to turn on blue and green you would pass 2^11 + 2^13, or 10,240 in base 10.

The RGB value of colors.orange is, by default, red 242, green 178, blue 51, as shown in the Display column of the table you reference.



#278065 computercrafts terminal

Posted by KingofGamesYami on 10 August 2018 - 08:37 PM in Ask a Pro

1. You can only use the built in colors; however in later versions what those colors are can be changed on the fly. Example: http://www.computerc...s-a-great-idea/
2. No.



#277680 Why CraftOS is better than Windows

Posted by KingofGamesYami on 04 July 2018 - 12:17 AM in Media

I have an Ubuntu VM through Virtualbox, it is very fast. I have allocated 4 cores and 11 GB of RAM to it though, so that probably helps.



#278840 Odd turtle.craft issue.

Posted by KingofGamesYami on 02 March 2019 - 11:46 PM in Ask a Pro

Sometimes line numbers are innaccurate. Can you verify that it is that line by adding some print statements?



#277677 Why CraftOS is better than Windows

Posted by KingofGamesYami on 03 July 2018 - 12:06 AM in Media

I for one welcome security updates and bug fixes. CraftOS in the last official release is laughably broken.



#278857 Odd turtle.craft issue.

Posted by KingofGamesYami on 04 March 2019 - 03:45 PM in Ask a Pro

Create a startup file



#278057 [SOLVED] calling code from string

Posted by KingofGamesYami on 10 August 2018 - 12:23 AM in Ask a Pro

View PostBrunoZockt, on 09 August 2018 - 07:58 PM, said:

I need to run code from a string (e.g. "if true then print("bla") end"). loadstring() doesn't work for me since I need to call functions that are not global but only exist within my program.

First off, WHY? There is most likely a MUCH better solution to whatever problem you have than doing this (which is why the default behavior is to not allow it).

View PostBrunoZockt, on 09 August 2018 - 07:58 PM, said:

the documentation of load() is so bad

It's actually very good, IMO.

Finally, neither example #1 nor example #2 work for me. A minimal reproduction is easy:

local foo = "Hello World"
print( getfenv().foo ) --# nil

Unfortunately, it is completely impossible to get locally delcared variables in ComputerCraft. In regular Lua it is possible to do via the debug library, but this is disabled for security reasons.

The easiest workaround would be to not declare your stuff as local. But that is going to pollute the global env. and do various bad things. A better workaround is to pass all the required variables to the function when it is called. If this is impractical, you might want to consider a different approach to whatever problem you're attempting to solve.



#277600 Need PROGRAM_FILES/JAVA/jre1.8.0_171

Posted by KingofGamesYami on 19 June 2018 - 01:38 AM in Ask a Pro

What exactly are you trying to open?



#277605 Need PROGRAM_FILES/JAVA/jre1.8.0_171

Posted by KingofGamesYami on 19 June 2018 - 11:34 AM in Ask a Pro

That makes no sense, why would Windows prompt you to open a standalone application (the java installer) with java or notepad?



#278352 How does your keyboard feels?

Posted by KingofGamesYami on 10 October 2018 - 10:15 PM in General

Was totally expecting r/mechanicalkeyboards but got this instead.

Mine's a bit dirty, mainly because it's attached to a laptop which I use for all of my computing needs. It's not bad though; the constant movement and use helps with that. Also since it cost almost $2k I tend to treat it nicely.



#278365 How does your keyboard feels?

Posted by KingofGamesYami on 11 October 2018 - 02:17 PM in General

View PostEveryOS, on 11 October 2018 - 11:47 AM, said:

:o/> Wow...

It was a worthy investment. Gets me through university without worrying about shit breaking plus has Dell ProSupport so if it *does* break, I have next-business-day service.



#277763 the HTTP API and the cookies

Posted by KingofGamesYami on 12 July 2018 - 09:49 PM in Ask a Pro

Cookies are in the headers, of course. You can't read the headers in any version of computercraft that has been officially released, but the latest version includes the ability to do so through the .getResponseHeaders method.

Reference: https://github.com/d...TTPRequest.java



#277770 the HTTP API and the cookies

Posted by KingofGamesYami on 13 July 2018 - 01:32 AM in Ask a Pro

It was added in 1.80pr0 or 1.80pr1 (unreleased).

The builds available on https://cc.crzd.me should include it.



#277753 [SOLVED] string.gmatch seems to steal letters

Posted by KingofGamesYami on 12 July 2018 - 01:22 AM in Ask a Pro

I think string.gsub( str, "minecraft:", "" ) would work much better in this case.



#277760 [SOLVED] string.gmatch seems to steal letters

Posted by KingofGamesYami on 12 July 2018 - 09:05 PM in Ask a Pro

You can easily create a custom pattern to match all letters and _. It'd look something like this: "[%a_]"



#277785 [SOLVED] string.gmatch seems to steal letters

Posted by KingofGamesYami on 14 July 2018 - 06:39 PM in Ask a Pro

Have you tried "^\"" yet? That will match everything except a double quote.



#278973 [CC 1.41] Lettuce's Improved Land-Clearing Program

Posted by KingofGamesYami on 30 April 2019 - 11:04 PM in Turtle Programs

View Postdoctorwhofan92, on 30 April 2019 - 08:53 PM, said:

Is there any chance this will be updated to work with the current(1.12.2) version of computercraft?

OP hasn't logged in since 2015 so I rather doubt they will respond.



#278478 Forums are completely locked off

Posted by KingofGamesYami on 05 November 2018 - 04:43 AM in Forum Discussion

View PostBomb Bloke, on 05 November 2018 - 02:05 AM, said:

Ironically, it looks like sign-ups over at that new site are broken too: no verification mails are hitting my email account.

Check your spam if you haven't already; my verification went straight there when I signed up.



#278475 Forums are completely locked off

Posted by KingofGamesYami on 04 November 2018 - 11:46 PM in Forum Discussion

We know. Dan200 is the only one who can fix it and he isn't responding to queries from the community nor the mods.

That's why computercraft.cc exists.



#278481 Forums are completely locked off

Posted by KingofGamesYami on 05 November 2018 - 01:12 PM in Forum Discussion

View PostBomb Bloke, on 05 November 2018 - 06:51 AM, said:

Har har, but it turns out the servers were simply tardier than most - I figured half an hour would be the upper limit on such things, but they actually took a couple of hours to come through.

Glad to hear it all worked out!