Jump to content


KingofGamesYami's Content

There have been 51 items by KingofGamesYami (Search limited from 29-March 23)


By content type

See this member's


Sort by                Order  

#279046 CC Standard Programs

Posted by KingofGamesYami on 27 May 2019 - 12:03 AM in Ask a Pro

View Postschrolock, on 26 May 2019 - 10:12 PM, said:

View PostLupus590, on 24 May 2019 - 04:39 PM, said:

you want a resource pack that you can put your code into, you can find a turtorial for that on the wiki http://www.computerc...king_(Tutorial)

i see. that's how it's down nowadays. but the tutorial doesn't say where to place the ressource packs. Also, will i still be able to use the standard cc programs?

* In the same folder as any other Minecraft resource pack.

* Yes.



#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.



#278857 Odd turtle.craft issue.

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

Create a startup file



#278851 [Solved] Compare two Tables

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

The error message clearly states your problem:

You have treated components as a function and placed parentheses after it as if to call it. Unfortunately it is not a function and so the error.



#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?



#278796 Expanding the screen

Posted by KingofGamesYami on 08 February 2019 - 12:18 AM in Ask a Pro

Why?

What value is there to shifting the arbitrarily defined values for minimum and maximum coordinates?



#278793 Expanding the screen

Posted by KingofGamesYami on 07 February 2019 - 08:27 PM in Ask a Pro

You *can* set the cursor position offscreen. It just won't display anything you draw offscreen. Easy test:

term.setCursorPos(-1,1)
term.write("Hello, World")



#278617 Is it possible to get variable name from table

Posted by KingofGamesYami on 12 December 2018 - 05:36 AM in Ask a Pro

You can't make a table entry local. The table itself sets the scope for entries.



#278602 Printing float digits...

Posted by KingofGamesYami on 09 December 2018 - 09:50 PM in Ask a Pro

Think about what num % 1 would return if there is no decimal. You can come up with a simlple program similar to the one you have now with that information.



#278570 Saving Table To File With Functions

Posted by KingofGamesYami on 26 November 2018 - 10:29 PM in Ask a Pro

The reason that error occurs is because there is no way to create a string from a function that is guaranteed to work the same after converting it back to a function.

As you are writing the function in question, just write it as a string in the first place. You can later use loadstring and pass arguments to it using varargs (as is done with programs).



#278550 Creating multiple objects in different coordinates

Posted by KingofGamesYami on 22 November 2018 - 05:25 PM in Ask a Pro

Its not random. Nowhere in the original post did you specify any degree of randomness. You could add a random number between -2 and 2 to each x and y coordinate to make it appear somewhat random, or you could get into actual procedural generation which is a bit more complicated.



#278548 Creating multiple objects in different coordinates

Posted by KingofGamesYami on 22 November 2018 - 04:25 PM in Ask a Pro

I can't go into great detail right now b/c im on my phone, but essentially I generate an x and y coordinate every 5 with an offset like (15,15), (20,15) ... up to the number of trees requested. The coordinates are also placed inside the smallest square that can contain that many trees, by finding the side length of a square of that area and rounding up. So requesting eg. 20 trees would get 4 < sqrt(20) < 5 and would round up to a 5x5 square.

It's mostly just basic algebra, tho modulus isn't really taught in school. Basically it returns the remainder of dividing, so 8 % 7 would return 1, or 8 % 4 would return 0.



#278546 Creating multiple objects in different coordinates

Posted by KingofGamesYami on 22 November 2018 - 12:38 PM in Ask a Pro

Well, I'd generate position based on ID. Lets say you want to make (approx) a square.
-- where to start from
offsetx, offsety = 10, 10 
-- how many trees in a row
sideLen = math.ceil(math.sqrt(number_of_tree))
-- spacing
spacing = 5
for id = 1, number_of_tree
  x = (id%sideLen * spacing) + offsetx
  y = (math.floor(id/sideLen) * spacing) + offsety
end

This assumes you're counting up in both x and y. It can be modified to do generate in the negative direction as well. You can also easily make a formula to get id from coordinates.



#278525 Portable Computers and Touchscreen Menus

Posted by KingofGamesYami on 14 November 2018 - 05:18 AM in Ask a Pro

I recommend taking a look at the touchpoint API. It handles all the difficult stuff for you, you just have to tell it where each button is and what it should do.



#278511 Here's a quick error problem.

Posted by KingofGamesYami on 09 November 2018 - 04:21 AM in Ask a Pro

Huh, I did not know that. NFP was originally used by NPaintPro which supports more than the default paint program. I retract my earlier statement.

http://www.computerc...-145-npaintpro/



#278509 Here's a quick error problem.

Posted by KingofGamesYami on 09 November 2018 - 02:30 AM in Ask a Pro

Probably not related to the actual error, but paintutils doesn't handle the nfp format.



#278497 Use more grayscale!

Posted by KingofGamesYami on 05 November 2018 - 10:52 PM in General

What've you got against the hot dog stand theme?

Just kidding, I agree with you. Grayscale looks awesome.



#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!



#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.



#278472 Weird error?

Posted by KingofGamesYami on 04 November 2018 - 09:46 PM in Ask a Pro

There is no functional difference between deleting inside a program and deleting manually.



#278445 Happy Halloween

Posted by KingofGamesYami on 31 October 2018 - 06:19 PM in General

Where is my friend the Almond Joy?

As for costume: I'm a cheap & lazy college student so none. But if I wasn't I'd be going as a segfault.



#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.



#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.



#278225 How to write programs in reasonable time?

Posted by KingofGamesYami on 04 September 2018 - 01:11 AM in Ask a Pro

Just allocate like an hour per day to writing just this one program or something. Many programs might not even take that long, if they're simple enough.

But you'll never make everything. I have dozens of projects that never made it to the forums or are on indefinate hiatus.