Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Search - "lua"
-
Girl: "hey"
My Brain:
java.lang.NullPointerException:
at net.brain.functions.Talk.retrieveSpeech(Talk.java:2978)
at net.brain.functions.Talk.createFlirtyResponse(Talk.java:3132)
Me: null
*Girl walks away*20 -
A little bit of Lua in my life
A little bit of Java by my side
A little bit JS is all i need
A little bit of bash is what i see
A little bit of JSON in the sun
A little bit of Python all night long
A little bit of TCL here i am
A little bit of this makes me your dev17 -
Uncle: "It must be noisy, programming. I've seen a datacenter on TV, and those computers are loud" — "It is noisy, but that's more my coworkers fault"
Sales guy at the office: "So you see patterns in the code, you can read this cryptic mess?" — "Uh this is PHP, Its not the syntax that makes it hard to read, it's the dimwit who wrote it"
Father-in-law: "Could you reprogram my laptop, I got a virus trying to download por... nature documentaries" — "I'm not that kind of doctor"
Mother-in-law: "How will you sustain a family, you just play video games all day" — "I make your monthly teachers salary in four days"
Girlfriend: "I learned some Lua today because I needed a world of warcraft extension for..." — "I love you too"22 -
Person: I want to learn to code neural networks and cool AI stuff.
Me: Look into Python or Lua.
Person: Those are too hard, I'm going to use HTML instead.
I got out of there as fast as I could. 😅11 -
My wife is a (semi-)pro gamer, so the only way it affects our dating is that I have to help her write LUA addons, performance analytics and Twitch bots.18
-
Friend: Can you teach me to code??
Me: Hell yes, bout time you came to your senses.
Friend pulls out iPad: Okay, lesson one!
Me: Did you actually just pull out an iPad? Get a fucking computer or laptop!9 -
"Running the sample code is easy! Just git clone, make sure python, lua, gcc, docker and cuda are installed, and run ./install.sh. Easy!"
Me: Light 6 candles, sprinkle some thyme water with unicorn tears over my keyboard, start chanting an unholy hymn... shit... some compiler error from a library I've never heard of before.
Why can't these "interesting samples" come with easy pre-compiled binaries...18 -
Me *shows friend website hosted on Ubuntu VPS*
Friend: You using UBLUNTOOTH?
Me: Excuse me? This is going on devRant.6 -
I had to open the desktop app to write this because I could never write a rant this long on the app.
This will be a well-informed rebuttal to the "arrays start at 1 in Lua" complaint. If you have ever said or thought that, I guarantee you will learn a lot from this rant and probably enjoy it quite a bit as well.
Just a tiny bit of background information on me: I have a very intimate understanding of Lua and its c API. I have used this language for years and love it dearly.
[START RANT]
"arrays start at 1 in Lua" is factually incorrect because Lua does not have arrays. From their documentation, section 11.1 ("Arrays"), "We implement arrays in Lua simply by indexing tables with integers."
From chapter 2 of the Lua docs, we know there are only 8 types of data in Lua: nil, boolean, number, string, userdata, function, thread, and table
The only unfamiliar thing here might be userdata. "A userdatum offers a raw memory area with no predefined operations in Lua" (section 26.1). Essentially, it's for the API to interact with Lua scripts. The point is, this isn't a fancy term for array.
The misinformation comes from the table type. Let's first explore, at a low level, what an array is. An array, in programming, is a collection of data items all in a line in memory (The OS may not actually put them in a line, but they act as if they are). In most syntaxes, you access an array element similar to:
array[index]
Let's look at c, so we have some solid reference. "array" would be the name of the array, but what it really does is keep track of the starting location in memory of the array. Memory in computers acts like a number. In a very basic sense, the first sector of your RAM is memory location (referred to as an address) 0. "array" would be, for example, address 543745. This is where your data starts. Arrays can only be made up of one type, this is so that each element in that array is EXACTLY the same size. So, this is how indexing an array works. If you know where your array starts, and you know how large each element is, you can find the 6th element by starting at the start of they array and adding 6 times the size of the data in that array.
Tables are incredibly different. The elements of a table are NOT in a line in memory; they're all over the place depending on when you created them (and a lot of other things). Therefore, an array-style index is useless, because you cannot apply the above formula. In the case of a table, you need to perform a lookup: search through all of the elements in the table to find the right one. In Lua, you can do:
a = {1, 5, 9};
a["hello_world"] = "whatever";
a is a table with the length of 4 (the 4th element is "hello_world" with value "whatever"), but a[4] is nil because even though there are 4 items in the table, it looks for something "named" 4, not the 4th element of the table.
This is the difference between indexing and lookups. But you may say,
"Algo! If I do this:
a = {"first", "second", "third"};
print(a[1]);
...then "first" appears in my console!"
Yes, that's correct, in terms of computer science. Lua, because it is a nice language, makes keys in tables optional by automatically giving them an integer value key. This starts at 1. Why? Lets look at that formula for arrays again:
Given array "arr", size of data type "sz", and index "i", find the desired element ("el"):
el = arr + (sz * i)
This NEEDS to start at 0 and not 1 because otherwise, "sz" would always be added to the start address of the array and the first element would ALWAYS be skipped. But in tables, this is not the case, because tables do not have a defined data type size, and this formula is never used. This is why actual arrays are incredibly performant no matter the size, and the larger a table gets, the slower it is.
That felt good to get off my chest. Yes, Lua could start the auto-key at 0, but that might confuse people into thinking tables are arrays... well, I guess there's no avoiding that either way.13 -
Network-connected train displays, failing and displaying their IP address, on a train that has WiFi on board. That's just begging to be hacked.19
-
A Fellow Ranter said I should introduce myself, so here I go.
Me = {
Gender = "Male",
CodeOfChoise = {"lua", "PHP"},
Age = "28"
Location = "404"
}
No really here we go, I am Rex, I am dyslexic and forget code really badly but it does not stop me from trying to have fun with some ideas, I use mostly PHP these days but when I want to make a quick windows tool I use a app called AMS or AutoPlayMedia Studios what as a nice lua scripting language back end.
I been coding on and off for many years since I was about 15 and I been in love with computers since I was about 6 (don't tell my wife).
So far I like the site, its better then Twitter and Facebook as it's code related and fun to read and some stuff gets the cogs a turning.
I don't have any real foot print in the dev world, I get by but I not here to be loved, or to be big in any field, I am here because I enjoy my tech.
I leave this little introduce me with a question, what was your first or first memorial computer.
Mine was the Acorn A4000 Mixed with parts from the A3000 and A5000's :) she was a little bit of a mix match.18 -
I'M SO PROUD, I WROTE A FULLY-FUNCTIONAL JSON PARSER!
I used some data from the devRant API to test it :D
(There's a lot of useful tests in the devRant API like empty arrays, mixed arrays and objects, and nested objects)
Here's the devRant feed with one rant, parsed by Lua!
You can see the type of data (automatically parsed) before the name of the data, and you can see nested data represented by indentation.
The whole thing is about 200 lines of code, and as far as I can tell, is fully-featured.24 -
When you are programming and you press some random keybind and you spend the next hour trying to figure out what you did 😐8
-
who ever has this as their skill set are legends!!
made me laugh going through thousands of lines of skills :D
"
A little bit of Lua in my life
A little bit of JS is all i need
A little bit of bash is what i see
A little bit of JSON in the sun
A little bit of Python all night long
A little bit of TCL here i am
A little bit of this makes me your dev
"1 -
Friend: "what is the answer to this question?"
Me: "${answer}"
Friend: "yes, what is the answer?"
Me: "my bad"
Me: `${answer} is the answer`
Friend: "thanks man" -
If I ever develop a game:
if(username.startsWith("Xx") && username.endsWith("xX")) this.username = "XxNoneOfThisxX";5 -
Solving Errors:
Code it.
Doesn't do anything, no errors in console.
Try again.
Doesn't work.
*Realizes that you didn't call the function*
ffs1 -
I know it's not done yet but OOOOOH boy I'm proud already.
Writing a JSON parser in Lua and MMMM it can parse arrays! It converts to valid Lua types, respects the different quotation marks, works with nested objects, and even is fault-tolerant to a degree (ignoring most invalid syntax)
Here's the JSON array I wrote to test, the call to my function, and another call to another function I wrote to pretty print the result. You can see the types are correctly parsed, and the indentation shows the nested structure! (You can see the auto-key re-start at 1)
Very proud. Just gotta make it work for key/value objects (curly bracket bois) and I'm golden! (Easier said than done. Also it's 3am so fuck, dude)15 -
git commit -m "Forgot a semicolon"
[master 92asd32] Forgot a semicolon
1 file changed, 1 insertion(+), 1 deletion(-)7 -
Got Ubuntu on my laptop for traveling 😁😁 Loving it, once I got Numix theme installed I loved it even more 😋
No one in my classes have ever heard about Linux or Ubuntu until they met me.8 -
When you're looking for answers on Google and you come across that one thread that goes on forever; you read every last response. You finally reach the ended to see:
"Thread locked.
Issue Resolved."
You never found your answer. -
Presenting: my weather app (not made by me).
https://play.google.com/store/apps/...
"The Fucking Weather"10 -
They really need to improve the algorithm that is searching for things in Windows Explorer. Literally:
Windows: *Searching for files in Downloads*
Me: I just typed .mp4, what is taking so long!?
Windows: *No results.*4 -
Is this just me?
if(..... expression.....){
System.out.println("it works, calm down");
} else{
System.out.println("it's not fucking working, holy fucckk, fucking WORK");
}
Tell me if you do something similar.6 -
When you trying to develop a site, you change some CSS, refresh the localhost and it doesn't update. You try changing that CSS value to something more noticeable to see if you're just imagining things. But no, it's your browser cache. Clear it.2
-
And already, I have completed my New Year's resolution! (SPEED RUN!)
I've just published my first completed project!
https://algorythm-dylan.github.io/t...
It allows you to make advanced cross-platform console applications. It's cross-platform curses, basically.
I spent quite a lot of time on the docs, so you can read all about it there. There's still a lot of stuff to do, but the very foundation is there, and it's everything you need(ish). It can just be a little inconvenient at times without helper functions for drawing, or adding strings, and such.
I'm currently binding it to Lua, which is going to be super fun to use!
Happy with this first version5 -
Is Santa coming to your house? Use my "advanced" algorithm to find out.
Person kid = getKidByName("yourName");
FatGuy santa = new FatGuy("santa");
if(!kid.wasNaughty()){
System.out.println("Good child");
santa.sendGift(kid, "train");
return;
}
System.out.println("You're on the naughty list");
santa.sendGift(kid, "coal");15 -
When I hear people talk about love and the first thing that comes to mind is the Lua framework for 2D game development4
-
Should I actually look into getting a dev job..?
*I have a high school diploma (graduated three years early)
*College dropout (3-4 months, Computer Science - Personal Reasons)
*No prior work experience.
*Good textural communication skills, poor verbal communication skills.
*Currentally unemployed. (NEET :P)
*I have extensive personal experience with Java, and Python. Some Lua. Knowledge of data generation, parsing, Linux, Windows, Terminal(cmd & bash), & Encryption(Ciphers).
*Math, but very little algebra/geometry (though, could easily improve these).
*Work best under preasure.
Remote only.
Think anyone would hire me..?13 -
> Make a small game.
> Do it in Rust because why not.
> Decide "Hey, why not make the game objects have Lua scripts for their logic because Lua is easier to do quick and dirty code in than Rust?"
> 5 hours later delete all the code related to running the Lua in Rust because AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA1 -
>dad nagging to learn python
>i hate python
>cuz i hate snakes
>whatever
>so started learning it
>with some awesome video tutorials
>even though i like the instructor
>i find the language
>boring
>uhh
>why do u use this?
>oh and you say it is easy 4 begineers
>oh good
>then why does only
>del keyword gets highlighted in pycharm
>just to look cool i guess
>lua is way better
>hope lua is more used than python
>and more supported
>but i still like C#
Moral: C# rocks10 -
Hello devRant, this is going to be my first time posting on the site.
I work for a gaming community on the side, and today one of the managers asked me to implement a blacklist system into the chat and reactivate the previously existing one temporarily. This shouldn't have had any issues and should've been implemented within minutes. Once it was done and tested, I pushed it to the main server. This is the moment I found out the previous developer apparently decided it would be the best idea to use the internal function that verifies that the sender isn't blacklisted or using any blacklisted words as a logger for the server/panel, even though there is another internal function that does all the logging plus it's more detailed than the verification one he used. But the panel he designed to access and log all of this, always expects the response to be true, so if it returns false it would break the addon used to send details to the panel which would break the server. The only way to get around it is by removing the entire panel, but then they lose access to the details not logged to the server.
May not have explained this the best, but the way it is designed is just completely screwed up and just really needs a full redo, but the managers don't want to redo do it since apparently, this is the best way it can be done.7 -
didn't think it'd ever happen but I had to talk a client out of having background music on their site 🙄6
-
Here's one that involves Windows, Linux (at the same time!), WInZip, Python, Lua and Minecraft, sort of.
So, when I get depressed I often find that old 2011 Minecraft videos help a lot from the nostalgia boost. If its stupid, but it works, it isn't stupid. Anyways, I was thinking about how much fun it must have been to just fuck around with code and make something like Minecraft. Naturally, I got a huge code boner and really wanted to do something I hadn't in a while: binding c to a higher level language.
This time around, I wanted to try Python. C + Python seems like a good pair. I watched a tutorial and it seemed pretty interesting and simple enough but I remembered that I actually like Lua a lot better than Python, so I went to the download page of Lua.
The download is a tar.gz so I let out a sigh and start typing "WinZip" into google. But no, fuck that, I hate 3rd party decompression programs on Windows. They all just give me this eerie feeling.
"This would be so much fucking easier on Linux"...
I remember that I haven't tried the Windows Subsystem for Linux. I guess it's time, isn't it?
I read the docs of how to do it. Nice little touch, they tell you how to enable WSL from PowerShell but don't mention the GUI way to do it. It's genuinely a nice touch.
So I get everything installed and go to the app store to choose a distro. I want Ubuntu. I click the Install button...
...
... "Something unexpected happened"
Windows and their fucking useless error messages. Jesus, okay. I restart computer. Same issue. I update Windows. Same thing. Uninstall WSL. Reboot. Install WSL. Reboot. Same thing. HOLY SHIT.
Went to bed. Woke up. Tried to install Ubuntu.
"Yea ok lul i'll work this time for no reason"
Finally unzipped Lua.4 -
I think I'm not as socially awkward as I once believed. I realize I just have nothing in common with the majority of people.
I don't watch sports, I don't care about cars, or fantasy football, or have any hobbies non-developers would find interesting.
If you want to talk about software patterns, finite automaton, Lua/C APIs, etc, then fuck yeah I'll talk to you all day long.5 -
Hey guys I'd like to share a Lua-based shell I've been working on the past few years. It's entirely complete, allows for all windows and Linux commands. I've been working very hard on it so I'm super excited to share it with you all. Here's the source.
--[[
The Lua Shell (lush) by AlgoRythm
]]--
while true do io.write(">> "); os.execute(io.read()) end4 -
Just found out about Yue, a GUI library for Node.js, Lua and C++ (and owners of the "gui" package on npm).
It is so awesome! The RAM usage is so low compared to Electron! Of course it has its limitations and doesn't use HTML + CSS + JavaScript, but you can still build really good applications with it!
I'll show you what I'm making at the moment soon, so stay tuned!
Anyways I've built the same application in Electron and Yue, here's the comparison of the RAM usage:16 -
@echo off
color a
echo Hacking...
ping localhost -n 5 >nul
color c
echo Failed, aborting...
ping localhost -n 3 >nul
pause4 -
Those channels on YouTube that read Reddit posts, except they don't and they just copy paste text into Cepstral to have a robot voice. Effortless! I am going to make a SIMPLE Python script that makes those very same videos except at 10x the speed to show how easy it really is!8
-
Wow, I think I might be closer to done than I thought I would be!
Double buffered console library, works cross-platform with support for color! Color was a challenge because of the differences between Linux and Windows but I think my solution was okay!
The only thing I have left is reading input and I don't think that's going to be terribly hard! Then, I'm gonna bind it to Lua and make really cool console applications like a portable console notepad lol.
Pic attached.5 -
Progress: I have Lua code running, however it returns an error every time.
An error containing the result I wanted.3 -
------------Weeklyrant-------------------------------------
So I bought a smart watch to go with my Samsung Galaxy back when I was 12, and upon inspecting the watchface maker app I came across lua scripting files. This amazed me. Animations, complex math, hexadecimal color system, variables, sensors...
I spent about four months
learning/experimenting with lua until I discovered arduino and C++.
I am now 14 and have been fascinated with robotics and learned java and dos since.2 -
Learned Lua for an hour, I think its a fun language to mess around, but i’m still figuring out what i’m going to use it for...10
-
Friend: You haven't been programming all day have you? It's been 10 hours.
Me: pfft, I haven't been programming all day, I have a life;3 -
That specific moment a C# Developer (me) makes an API for Modding his own game but the mod language is Lua.
(And it works)6 -
Dear algo,
Please stop giving me 30 day old posts, I know I've ++'d one or two here and there, but that does not mean I like specifically old posts. Also I'd rather not be "that guy" that reminds the poster of that post they made a month ago.4 -
If you hate creating regex strings, this site makes it fun and easy:
https://regex101.com
Thought I'd share :P2 -
Reading about Lua, see this:
"Lua arrays are 1-based: the first index is 1 rather than 0 as it is for many other programming languages (though an explicit index of 0 is allowed)."
*close tab*2 -
String username = "Xx_thelegend27_xX";
final Pattern pattern = Pattern.compile("(xx|(_|))(?<username>\\w*)(_|(xx))", Pattern.CASE_INSENSITIVE);
final Matcher matcher = pattern.matcher(username);
if(matcher.matches()){
this.showError(String.format("Your username cannot be that... Try: %s", matcher.group("username")));
}else {
registerOrSomething();
}2 -
Customer: I want to be included in any and all design and development meeting in the future.
Me: OK, I mean, I'm just one person so there's not formal meetings as such...
Customer: Nevertheless, I wish to be included and ensure my needs are met.
Some time passes.
Me: So, I'm thinking of swapping out the old Beanshell interface, cos, really... Interpreted, scriptable Java isn't great and most users don't want to write Java just to run some jobs. Could you help me with creating an API that fits you and your departments needs?
Customer: No, I'm way to busy to deal with this right now!
Me: And when would be convenient for you?
Customer: I don't know, just not now.
To this day, despite successfully integrating the rhino js engine into the app, part of the software I develop has a bean shell interface rather than js, Python or lua.
-_- I hate bean shell... -
My internet provider is a fucking joke. Joke as in my internet is so garbage that it'd be better if I didn't have any internet at all.2
-
I just found out that my partner writes his increment operators with a space between the variable and the operator.
i ++;
anybody else do that because he's changed parts of our code to include the space and it's frustrating7 -
What is your opinion on hopping from one language to another?
So far I have been programming for a little over a year and have used Python, Lua, Javascript amd C++, planning on trying Java in the very near future.
I've had quite a positive experience with switching languages so far, especially when starting out. Some concepts I wouldn't understand, but after seeing them from a perspective of a different language I finally got it. Do you think it's good to know a lot of languages, or in the long run is it better to master one?8 -
The English language.
Maybe my fascination with code that reads like a book comes from a desire for my code to be understood. Maybe it comes from novelty. But it really does send tingles down my spine when it reads like literature.
That's one of the largest reasons Lua is my favorite language and Java is one of my least favorite (sounds like a guy with a bad stutter, always repeating himself)2 -
When you're done a project for someone that took 3 weeks: so you ask them to pay, and they tell you they don't want it anymore. THE FUCK2
-
Another update on my 3D Software Engine:
Big progress since my last rant.
I now have a simple lightning with the Gouraud Shading Algorithm!
Looks really cool now!
Btw for those who are interested, I am following a tutorial but I'm translating everything to Lua/LÖVE2D. Here's the link to the tutorial:
https://davrous.com/2013/06/...8 -
I don't get it.
I tried Kotlin on Android just for fun, and it doesn't support binary data handling, not even unsigned types until the newest version. Java suffers from the same disease.
How does one parse and process binary data streams on such a high end system? Not everything is highlevel XML or JSON today.
And it's not only an Android issue.
Python has some support for binary data, and it's powerful, but not comfortable.
I tried Ruby, Groovy, TCL, Perl and Lua, and only Lua let's you access data directly without unnecessary overhead.
C# is also akward when it comes to data types less than the processer register width.
How hard can it be to access and manipulate data in its natural and purest form?
Why do the so called modern programming language ignore this simple aspect that is needed on an everyday basis?11 -
Making games for my TI-Nspire CX CAS is so much fun!
It's so simple but you can do a lot with it. It's also a bit of a challenge because you don't have a huge API with lots of methods and events. You have to use what you have.
Oh btw you can program it with Lua!15 -
I wrote a little script that generates random numbers until it reaches 420, my luckiest go was 17. What was yours?
Script: https://sharecodesnippet.com/40622 -
Who thought Lua was a good idea for extending gameplay functionality??
It's weakly typed, has no OOP functionality and no namespace rules. It has no interesting data structures and tables are a goddamn mystery. Somebody made the simplest language they could and now everybody who touches it is given the broadest possible tools to shoot themselves in the foot.
Lua's ease of embedding into C++ code is a fool's paradise. Warcraft 3's JASS scripting language had way more structure and produced much better games, whilst being much simpler to work with than Lua.
All the academics describing metatables as 'powerful extensionality' and a fill-in for OOP are digging the hole deeper. Using tables to implement classes doesn't work easily outside school. Hiding a self:reference to a function inside of syntactic sugar is just insanity.
Nobody expects to write a triple-A game in lua, but they are happy to fob it off to kids learning to program. WoW made the right choice limiting it to UI extensions.
Fighting the language so you can try and understand a poorly documented game engine and implement gameplay features as the dev's intend for 'modders', is just beyond the pale. It's very difficult to figure out what the standard for extending functionality is, when everybody is making it up as they go along and you don't have a strongly-typed and structured language to make it obvious what the devs intended.
If you want to give your players a coding sandbox, make the scripting language yourself like JASS. It will be way better fit for purpose, way easier to limit for security and to guarantee reasonable performance. Your players get a sane environment to work in and you just might get the next DOTA.
Repeatedly shooting yourself in the foot on invisible syntax errors and an incredibly broad language is wasted suffering for kids that could be learning the programming concepts that cross all languages way quicker and with way more satisfying results.
Lua is hot garbage for it's most popular application, I really don't get it. Just stop!24 -
Lua is one of the stupidest languages to ever exist.
Oh, the language is easy to learn? The syntax is friendly? There's only like negative 10 functions you ever need to know? Everything is a table?
EVERYTHING IS A TABLE?! WTF CARES? WHAT ABOUT NIL?!
The arrogance this language has is extraordinary, literally. No lang, except Lua, imposes such an opinionated dichotomy. Everything is a fucking table, or, it's nil. -- That's so fucking stupid.
And look, I get it, this lang (oh sorry, scripting language (?)) CAN be good and fun and whatever... the moment you start to do IO is the literal end of days.
Everything is nil. Except, if it's defined... then it's not nil. -- OK. That sounds sensible/reasonable enough. -- What if it's not defined? You get nil. What if it's not the right data? You get nil. Do I get errors/exceptions or whatever? No, absolutely not, you get nil... unless the application you're using with Lua with has a lib that handles that.
There are so many more issues I have with this lang, but honestly... Am I fucking missing something? Is this lang like actually super dooper awesome and I'm missing something? -- I can't not look at this language as just dumb and arrogant. -- It's literally a language where you have to manage and remember ALL conceivable state at ALL times.11 -
I started with C#at the age of 12, it was way too complicated and I learned Lua for Computer craft instead. Next I learned Ruby for RPG Maker and finally Javascript for web Dev stuff.
Now comfortable enought with Javascript but put off by its quirks I learned Java for compiling faulty minecraft mods, but I only fully learned it in school.
At the same time I learned python and quite liked it for scripting, but ultimately it was not a good match for my projects.
Disapointed with Java I returned to C# and liked it quite a lot, but started learning C++. After touching my first Microcontroller I learned C and I've stuck with it as my favorite language.
Along the way I picked up Kotlin, in case I need to do some Java shit. Much better.
But how did I come to an understanding of programming. Well I got better after each time I got a layer deeper until I hit silicon.
I had tinkered with electronics since I was 15 so I just had to study some boolean mathematics in school and some vintage computers architecture and instruction sets and...
Then I finally understood how that shit I wrote in Lua way back when was actually executed by my hardware.
Allways dig deeper and you'll find enlightenment eventually. -
Hey everyone!
I'm on the hunt for new and exciting languages!
I'll state the ones I already know:
Python, Haskell, C(++), C#, Java, JavaScript, Ruby, Rust, Lua, about every kind of Basic, some branches of Lisp, BrainF**k, assembly, Octo (Chip-8) and GML(basically JavaScript).
I've also learnt some styling languages:
Html, CSS, Markup and Markdown.
Some misc languages too: Regex and a runny bit of the Wolfram Language.
Also I'm kind of limited to Windows, Linux and Android, as I do not own any Apple hardware except I have access to an old iPad, so are languages like Swift still good?
Thanks!28 -
I made a my first tutorial!
Please don't complain about the mic :( I Know it's terrible. The only mic I have is a gaming headset.
https://youtube.com/watch/...12 -
To everyone who wants a terminal editor but hates how overly complicated vim/emacs is:
Micro is like nano but with lua extensions and multiple tabs.2 -
YouTube is so fuckin weird. A year ago I made some Lua tutorials and got no new subscribers. When I started, I had 8.
I have not posted any since.
But since then, I get a steady few per month.
I have over a hundred now?6 -
Lua, tables ("arrays") start at 1.
It also has no sleep function and its defacto package manager (luarocks) has almost never worked for me without some serious fuckery7 -
When Microsoft buys GitHub, but they can't steal your code because your code has been uploaded obfuscated.
*I am sorry for mentioning Microsoft and/or GitHub, it is quite repetitive* -
Me: *clicks on quick web design demonstration video*
All website builder ads: Fuck your entire profession!2 -
I recently got into an argument with some people, and I want your opinion. I did a speed code in Java (just sped up clip of programming, because it looks cool lol), and someone commented:
"Way too much static abuse here. Jesus"
In which I replied:
"Actually, sir. There is near none at all, just because I use static methods does not make it static abuse. A static method belongs to the class, and is somewhat permanent. It is not a type (instance, cat, dog, animal, etc.) class, it is a Utility class, much like other dependencies you'd use are Utilities and not types."
To which they reply:
"Getting and setting is a Utility?"
Boi. If it is a static variable, yes. Like, what?5 -
Holy fuck... Ruby has the best fucking syntax ever!
Ruby is so awesome!!!! (But Lua is a bit better)9 -
Just spent forever trying to figure out why my POST request parameter(s) weren't working. The PHP was checking for GET parameters. Fucking hell.1
-
Chased a bug for nearly a week. Huge code base, over 2mn lines consisting of a mess of C++, Python and Lua glued together.. Wrote a very complex distributed computational framework. End up with a elusive compiler bug in GCC.. FML
-
That feeling when you spend two hours trying to crack an array sorting exercise for college and finally get it right3
-
Why isn't the Lua scripting language widely used in the industry? It's flexible, modular and it's packages aren't bad; seems like a great fit.8
-
Does LUA have anything similar to the GIL in Python? Because my code seemed to be updating the same piece of memory at once
-
I used to think I was a great programmer, then I joined a computercraft server, it makes you feel like an absolute noob 😕6
-
When your friends wants you to help them code in Java and they type
public void Main String
without any instruction ... -
Me: "I wanna mod Ikemen so it can have tag presets, a replay recording manager, a player card for online games, a gallery,..."
Windows: takes a whole day to update
Me: "I wanna mod Ikemen so it runs on Ubuntu" -
How does random number generation work? I'm curious. What are different methods in which you can generate random numbers?
If you could link me to an article or some docs, that'd be appreciated. How far does your understanding of it go?
Thanks for your time.6 -
So I installed a new Linux distro, and since the DE is Gnome, I wanted to spice things up with a Conky file.
I download my conky theme, extract it, and try to run it.
And it's broken.
Apparently, the Conky development team decided it would be a great idea to switch over to an ENTIRELY FUCKING NEW SYNTAX, LEAVING EVERY CONKY THEME WRITTEN BEFORE AUTUMN THIS YEAR USELESS
Oh, no biggie, I think. After all, the development did very graciously publish a Lua file to convert old conky configs to the new syntax.
Except no.
The file used to convert conky configs uses the old loadstring function, for which support was dropped in Lua 5.4
So not only did Conky make every config written earlier than this Autumn obsolete, the FUCKING TOOL THEY DEVELOPED TO HELP WITH THAT IS ALSO FUCKING BROKEN
Fuck Conky. I wasted 2 hours screwing with this broken-ass piece of shit3 -
On a website, using var something = $.parseJSON('{"with": "perfectly valid javascript in here"}') when you could just have done var something = {"native": "javascript goes here", "with": "no parsing needed"};
-
Lua users, have you used moonscript?
It's a little language that has it's own interpreter or can be compiled down to Lua and it's absolutely lovely (currently using it with Love2d).
Of course, as with most things, what I love about it also royally pisses me off sometimes.
For starters local has to be declared for variables, unlike lua.
Otherwise the variable goes to _
Also note, that some tutorials literally tell you the opposite.
all variables are local by default
unless you don't declare them
then they go to _ (throwaway)
Some tutorials get this wrong too.
all variables have to be declared local
except tables. failure to declare a table WITHOUT a local will cause things like
table.insert to fail with "nil" values for no god damn reason.
No tutorial I could find mentioned this.
Did you know we call methods with '\'?
By the way, we call methods with '\'.
Why? Who the fuck knows.
Does make writing web routes more natural though.
Variables in the parameters of new are declared and bound for you. Would have loved to know this before hand instead of trying
to bind to them like a fucking idiot.
Fat arrows are used to pass in self for methods.
Unless you're calling a method. Then you use backwards slash. This fact is unhelpful when you're a beginner and dealing with the differences between the *other* arrow, the backslash, the fat arrow, and the fact that functions can be called with or WITHOUT parenthesis.
And on that note..
While learning all this other shit, don't forget parenthesis are optional!
Except when they're not!
..Like when you have a function call among your arguments and have to disambiguate which args belong to the outer call and to the inner call! Why not just be fucking consistent?
But on the plus size, ":" is now used for what it should have been used for in the fucking beginning: binding values to keys.
And on the downside, it's in a language thats built on top of another language that uses it for fucking *method calls*, a completely
different fucking usage.
And better still, to add to that brainfuckery thats lost in the mental translational noise like static on a fucking dialup modem, you define methods with the fat arrow. Wait, was that the single arrow or fat one? Yeah the fat one. Fuck. But not before you do THIS shit..
someShit: =>
yeah, you STILL include the god damn colon just so when you're coming from lua you can do a mental double take. "Why am I passing self twice? Oh right, because fuck me, I decided to use moonscript." It's consistent on that front but it also pisses me off.
A lot of these are actually quality of life improvements disguised as gotchas, but when you're two beers in to a 30 minute headscratcher it sure doesn't fucking feel like it.
Nevertheless, once I moved beyond the gotchas, it was like night and day. Sure moonscripts takes a giant steaming dump all over the lua output, like a schizophrenic alcoholic athena from the head of zeus, but god damn, when it works it just WORKS.
Locals that act like locals? Check.
Sane OOP? Check.
Classes, constructors, easy access to class methods, iterators? Check, check, check, check, check.
I fucking hate ceremony. Configuration over convention is for cunts. And moonscript goes a long ways toward making lua less cunty.
If you've ever felt this way while using lua, please, give moonscript a try.
You'll regret it, but in a good way!6 -
Good evening programmers, IT's, devranters and memeians.
I would like to use a little bit of your collective conciousness - the hive mind if you will.
I've been working on my automation system for quite a while and I've received some exposure from non-programmers - which resulted in more questions than suggestions.
I would like to ask you guys to give me some suggestions as to what I could add to my system.. that is, if you have time..
The program in short (if you don't want to read the readme file) is an automation system scriptable in pure Lua.
It utilizes Selenium for web automations, NAudio for audio operations and Moonsharp as an interpreter.
While my tester friends say that they use it for the actual testing, I myself found it very useful in writting bots (for browser games for example).
Here's the github link: https://bit.ly/2GDu92g
Thanks a ton!
PS. Here's an unrelated image to draw your attention.6 -
Starting game modding on Garry's Mod 9 back in 2006. I was 14. I never thought it would turn into my career. Also I miss writing Lua3
-
After opening game files for Ragnarok Online and saw the quest files are human readable (lua or other scripting language). Had some Flash workshops to confirm my interest.
Later in college, I make games for every lecture projects (with my friends). Now our game studio is 7 years old.2 -
Every day is a new day to doom us all.
React Lua
A comprehensive, but not exhaustive, translation of upstream ReactJS 17.x into Lua.
https://github.com/jsdotlua/...1 -
Everyone I tell this to, thinks it’s cutting edge, but I see it as a stitched together mess. Regardless:
A micro-service based application that stages machine learning tasks, and is meant to be deployed on 4+ machines. Running with two message queues at its heart and several workers, each worker configured to run optimally for either heavy cpu or gpu tasks.
The technology stack includes rabbitmq, Redis, Postgres, tensorflow, torch and the services are written in nodejs, lua and python. All packaged as a Kubernetes application.
Worked on this for 9 months now. I was the only constant on the project, and the architecture design has been basically re-engineered by myself. Since the last guy underestimated the ask.2 -
Sitting in my beautiful chalet on this beautiful park. My garden nicely mowed. Sun in shining. Was in the zone the whole day. Now it's time to shift some gears and fetch some desperado's (will pass out after three probably, didn't drink for long time). Walk towards neighbor and drink together.
Life can be so beautiful14 -
I have always been interested in computers. when I was in second grade, I decided I was no good at electronic circuits, and decided I wanted to program instead. My dad told be to check out free basic, and I immediately downloaded FBIDE, and followed tutorial videos on YouTube. once I finished the videos, I started to write mad libs programs. I made various types of calculators, etc. and loved it, so later I learned a bit of VB. I messed with that a bit, but didn't like it too much, and started web developing. The moment I saw some JS code, it was like an instinctive second language to me. I learned js and started making some ugly, but cool interactive web pages. When computercraft came out for minecraft, I learned lua and got a deeper understanding of programming. Now, I am using node to build a personal-use IoT server and currently making a drone flight program using a raspberry pi3
-
I've been trying to sleep for a while now. Counting sheep isn't helping because now the sheep have a whiteboard and are writing down answers to fix my bugs :/
Edit: if you were wondering, there is 1 sheep as of right now -
When you upgrade to awesome 4.1 and have to weed through and refactor 863 lines of Lua (not including theme file) -_- i3 is looking pretty good right about now1
-
v0.0005a (alpha)
- class support added to lua thanks to yonaba.
- rkUIs class created
- new panel class
- added drawing code for panel
- fixed bug where some sides of the UI's border were failing to drawing (line rendering quark)
v0.0014a (alpha) 11.30.2023 (~2 hours)
- successfully retrieving basic data from save folder, load text into lua from files
- added 'props' property to Entity class
- added a props table to control what gets serialized and what doesn't
- added a save() base method for instances (has to be overridden to be useful beyond the basics)
- moved the lume.serialize() call into the :save() method on the base entity class itself
- serialized and successfully saved an entities property table.
- fixed deserializion bugs involving wrong indexes (savedata[1] not savedata[2])
- moved deserialization from temp code, into line loading loop itself (assuming each item is on one line)
- deser'd test data, and init()'d new player Entity using the freshly-loaded data, and displayed the entity sprite
All in all not a bad session. Understanding filing handling and how to interact with the directory system was the biggest hurdle I was worried about for building my tools.
Next steps will be defining some basic UI elements (with overridable draw code), and then loading and initializing the UI from lua or json.
New projects can be set as subfolders folders in appdata, using 'Setidentity("appname/projectname") to keep things clean.
I'm not even dreading writing basic syntax highlighting!
Idea is to dogfood the whole process. UI is in-engine rendered just like you might see with godot, unity, or gamemaker, that way I have maximum flexibility to style it the way I want. I'm familiar enough with constructing from polygons, on top of stenciling, on top of nine-slicing, on top of existing tweening and special effects, that I can achieve exactly what I want.
Idea is to build a really well managed asset pipeline. Stencyl, as 'crappy' as it appeared, and 'for education' was a master class in how to do things the correct way, it was just horribly bloated while doing it.
Logical tilesets that you import, can rearrange through drag-n-drop, assign custom tile shapes to, physics materials, collisions groups, name, add tag data to, all in one editor? Yes please.
Every other 2D editor is basic-bitch, has you importing images, and at most generates different scales and does the slicing for you.
Code editor? Everything behavior was in a component, with custom fields. All your code goes into a list of events, which you can toggle on and off with a proper toggle button, so you can explicitly experiment, instead of commenting shit out (yes git is better, but we're talking solo amateurs here, they're not gonna be using git out the gate unless they already know what they're doing).
Components all have an image assignable to identify them, along with a description field, and they're arranged in a 2d grid for easy browsing, copying, modifying.
The physics shape editor, the animation editor, the map editor, all of it was so bare bones and yet had things others didn't.
I want that, except without the historic ties to flash, without the overhead of java, and with sexier fucking in-engine rendering of the UI and support for modding and in-engine custom tools.
Not really doing it for anyone except myself, and doubt I'll get very far, but since I dropped looking for easy solutions, I've just been powering through all the areas I don't understand and doing the work.
I rediscovered my love of programming after 3-4 years of learning to hate it, and things are looking up.2 -
Okay, I want everyone to write code related to the holidays below! I look forward to seeing responses6
-
I think mine had to be when I was working with SQL and Lua. I was attempting to store some ints into the database but kept having it fail randomly. It was a 50/50 chance that it would succeed or fail. I tried reading errors (Limited on what I could see) after a while (Almost 3 days, since everything I could think of didn’t have issues and was completely lost) I realized the system another developer setup returned either string or int, thus it causing it to error out when I gave it a string. Once I added a tonumber statement, all my headaches went away.
-
Rant portion:
Fuck me, there's not a ton of great resources for Lua. I have the book, and it's actually fucking incredible, but as soon as I have a question which I would usually Google, either it's a SO question that almost hits the mark (but absolutely does not answer my initial question) or a mailing list that DOES answer my question but holy FUCK it's difficult to read!
I 100% recommend the Lua book, though. It's remarkably helpful and covers just about every little detail of the language and it's corresponding c API, and even some of how Lua works behind the scenes.
Non-rant portion:
Finished up the first version of my library and now I'm binding it to Lua and this time around I'm using all the best practices including setting and checking metatables so that Lua can't segfault. It's going great, I properly learned about the Lua stack, and I feel good. Cross-platform double-buffered command line via a scripting language... What a way to enter 2020. Everything went so smooth that I got to 3am before I realized what even happened.1 -
I discovered a language I didn't know AND i like.
It's not under active development anymore, but I decide it has a nice syntax. It's made by the writer of craftinginterpreters. There are still people writing some extensions for it.
I decided to implement socket support in it.
That went very well and the result is just BEAUTIFUL. But now, i have a collection of socket functions that require a file descriptor (sock) for every function like write, read and close. We're not living in the 90's. I want to do sock.send(), sock.write() and sock.close(). So socket as an object.
I wrote a wrapper and it is freaking TWO times slower! Hows that even possible.
I've made wrapping to object optional now. Bit disappointing.
The language shows off with benchmarks on their page. Their fibers can even be faster than Elixr. Yeah, if you only use the fiber and nothing else from language. I benchmarked string concat for example against python: 1000 times slower or so.
The source code of wren is so freaking beautiful. Before Lua was my favorite language regarding source. The extensibility is so great that I prefer to work on this one instead of my own language. They kinda made exactly what I wanted. I can't beat that.
For if you're interested: https://wren.io/
The slot way of communicating between host language (C) and child language (wren) seems odd at beginning but i became fan of it.
Thanks for listening to my ted talk.
What's your opinion about wren (syntax)?25 -
Can gamedevelopers stop using lua as their freaking scripting language..
Every time I try and figure out how tables work and think I finally get it it throws a big fuck you curve ball.
Oh and then they use json file to store the data of a table except that those json interfaces are complete retards.
If you are going to support json files then why the fuck won't you put in a small fucking inconsecential JS interperter so you can actually find some docs regarding more complex fucking docs then those simple minded t[guildName] = "guild"
Another thing, why the fuck does lua not use {} like every other langauge. I use those curly brackets to figure out where shit start and ends half the freaking time.
Fuck this I'm out for today...
And a big fuck you with both middle fingers to any dev that thinks lua is a great scripting language for plugins.3 -
LUA... its great! I love it... but WHY THE FUCK DOESNT LUA START COUNTING FROM FUCKING 0!!! WHY THE FUCK DOES IT START FROM 1! I SEARCHED HALF A FUCKING HOUR IN MY CODE AND IT JUST DIDNT WORK! then it hit me... LUA IS THE ONLY FUCKING LANGUAGE THAT STARTS FROM 1 and sure enough... after changes and testing IT FUCKING WORKED!
Fuck4 -
So LUA injector to Payday 2 requires on Linux certain library (libcurl3). So you know, sudo apt install libcurl3 and there you go!
You would think.
Apparently while you do that, the installation of libcurl3, it completely nukes your Steam installation... For some reason.
Can some please explain me, what the hell just happened? Please?1 -
When you figure out the solution to a problem you've been having for weeks and then half an hour later you come across a new one 😭
-
If languages had slogans...
1) Java -- Buy one get two for free on your delicious NPEs.
2) C -- I burn way too much calories talking, let's do some sign language. Now see over there... 👉
3) Python -- Missing semi-colon? Old method. Just add an extra space and watch the world burn.
4) C++ -- My ancestors made a lot of mistakes, let's fix it with more mistakes.
5) Go -- Meh. I can't believe Google can be this lazy with names.
6) Dart -- I'm the new famous.
7) PHP -- To hide your secrets. Call us on 0700 error_reporting(0)
8) JavaScript -- Asynchronous my ass!
9) Lua -- Beginners love us because arrays start at 1
10) Kotlin -- You heard right. Java is stupid!
11) Swift -- Ahhh... I'm tasty, I'm gonna die, someone please give me some memory.
12) COBOL -- I give jobs to the unemployed.
13) Rust -- I'm good at garbage collection, hence my name.
14) C# -- I am cross-platform because I see sharp.
15) VB -- 🙄
16) F# -- 😴8 -
Me: *pastes error message into search engine* && *clicks first result*
First Result: Hey I have a problem with *this error*
Thread replies:
Same
Me too
Same here, anybody know how to fix it?
Help me
This has been irritating me for the past 2 minutes, somebody please help
Me: *replies "same" on a two year old thread*
Fuck you.5 -
Just spent 3 hours looking for an error in the client program. I later found out that it was a server-side error :D
k m n -
I hate dual boot, it might seem strange, but those 13 seconds it takes to shut down the pc, turn it on, select linux on grub (well, Windows broke my grub, so I actually have to use a modified version made to avoid windows 10 trying to make my computer "not mine") and type my password are the reason I'm starting to get lazy...
And there's more! The time between the on button press and the moment I can start working on linux is something between 3 and 4 seconds, not too much, and it takes less yhan 2 seconds to shutdown, it's not a problem, on the other hand, windows takes 20 seconds to boot, and after typing my account details, I have to wait almost 5 minutes before I can play (285 second onaverage)...
Sooooooo... Garbagedos is there only for games, I don't have any tool but notepad++ (hate it) and a lua ide for modding, I'd like to format everything and make a gpu passthrough, but I have an i5 quadcore, I don't know if that's enough 😥1 -
Do you guys support today's youth learning how to code? If so, why? If not, why not?
I started coding when I was 11.13 -
Why should I give a fuck as to whether or not Google knows my location?
I fail to understand why people treat it as such a big deal, so please shed some light onto your side of the story if you do care.17 -
Everything startest with HTML. I got an awesome book about HTML/CSS and I just started learning and trying out some stuff. At the beginning I got a lot of help from my father but soon I created my own websites! I setup a free webserver and after some time, I met PHP. I made tons of stuff with PHP :)
After about 1 year of creating things with PHP, I learned Javascript. And with Javascript I got into game development. I created some games but I wanted more. So I tried Unity Engine. But... well... It was hard. Then I tried Godot Engine and I finally found a game engine wich I enjoy!
I created a lot of games.
Then in 2016 I met Lua, wich is my favourite language now! (But I didn't do much with it)
Later I also met Node.js but I'm still learning :)1 -
Couldn't be arsed with all the conditional compilation that angelscript required, so I dumped right back to good ol' lua for now.
Got lua in, vm started, loading strings and pushing/popping the stack.
Got SDL actually drawing as intended.
I don't know even half of what I'm doing.
Apparently header files that end in ".hpp" are specific to c++, while .h are for c headers.
I like the new SDL2 though, little bit different than SDL1. Not a lot of tutorials cover the difference, but I could kinda suss out from the documentation where I needed to adapt, even though I'm still pretty loose on the library, on the docs, and on c++ itself.
Still just a learning project.
Also, I'm continually surprised there isn't a portable, platform independent tool or little language just for replacing all pseudo-languages out there like .bat and .sh, and .zsh
Maybe even just a tool that standardizes it all, then takes config files that map the new standard to system dependant commands, so you can download the damn thing, configure the relevant environment variables, drop in the platform dependent configuration (or your browser or package tool detects what platform you are on and chooses the relevant package/download for your platform), write a console script and the tool automatically translates, and emits the system-relevant commands to that platform's console (so you don't even need much platform-specific code to do things like file access). -
A good day at work and I have a few questions about the green light to the meeting tonight but I will be back to normal in 30 of the day and I have been talking to him about refund my money laundering problems (everything was written by the keyboard autocomplete) 🤔1
-
Best/Worst dev experience 2017:
Well I started my DevRant-Stats site and got my RandomQuote bot up and running again (although the quotes aren't as good as before)
I also started a little company with my friend and made some sites for clients.
I reached #13 on Sololearn in Austria! Kinda proud of it.
I learned Lua and Ruby which are one my favorite languages now!
And as always I started some side projects that I've never finished...
Don't remember everything I experienced in 2017 but these are some I won't forget.2 -
When I first saw the .dev TLS was $200 are some odd dollars I was sad. But, that was early access as now they are cheap. Yay!5
-
Got VS running, SDL up and running and outputting, and angelscript included. Only getting linker errors on angel at the moment, not on inclusion, but on calling engine initialization.
Who knows what it is. Devs recommended precompiling but I wanted to compile with the project rather than as a dll (maybe I'm doing something stupid though, too new to know).
Goal is to do for sdl, cpp, and angelscript, what LOVE2d did for lua. Maybe half baked, and more just an experiment to learn and see if I can.
Would be cool to script in cpp without having to fuck with compilers and IDEs.
As simple as 1. write c++, 2. script is compiled on load, 3. have immediate access to sdl in the same language that the documentation and core bindings are written for.
Maybe make something a little more batteries-included than what lua and love offer out of the box, barebones editors and tooling and the like, but thats off in the near future and just a notion rather than a solid plan.
Needed to take a break from coding my game and here I am..experimenting with more code.
Something is wrong with me.8 -
So matplotlib can do 3d plots. However, when you try to then label your axes...
plt.xlabel("protocol") # ok
plt.ylabel("volume") # ok
plt.zlabel("time") # error: no such method zlabel (ಠ_ಠ)2 -
me ={}
function me.returned()
error, login = http.submit("devrant.com", {"Rexzooly", "magicSource"}, 20);
if error == 200 then
//Ya I logged in
retrun true
else
me.resetpassword();
me.returned();
end
end
me.returned().
As the function kind of says ... I AM BACK and I remembered to reset my password :P7 -
At some point I was watching a sethbling video about programming mining turtles in a Minecraft mod called computer craft, which uses a reimplementation of lua with some mod specific functions. This inspired me to learn lua, then as I got bored with that I started moving through different languages until I settled on primarily kotlin and rust1
-
Does anyone know any good resources for learning Lua?
(And possibly how to use it with games by Valve (e.g. TF2, GMod, CS:GO)?)2 -
my old game had this flow every time a client places an object:
Client A creates a new generic object, and attaches texture paths (yep, global paths are allowed), and... lua code as strings to it.
Client A sends the entire object list to the server
Server receives it, replaces it's own object list
Server copies the entire object list and sends it to all clients
Client A and Client B both receive the object list and replace their versions.
All clients see that the object contains some code as strings
They compile and store it, and then run every frame. UNSANDBOXED.
any client could make all other ones execute any code and i was proud of my idea! -
Why is it when I tell someone I am a developer and I know how to program, they think "oh shit, he's a hacker" -.-3
-
I started in Lua in a program called AMS (it made autorun programs but has full scripting support making it pretty powerful) making little software applications.
That evolved into PHP and shortly after JS, HTML and CSS.
After a while i added other languages and it continues to grow today.
The UI aspect has just been something i have always had an eye for. -
Is this okay, why or why not? (I see this used that's why I ask
public static Main instance = new Main();3 -
With a background of predominantly C style languages and Lua, it's quite refreshing to be able to jump into Python and feel comfortable in it's usage. I've been running through some exercises (https://www.practicepython.org/) and am having a pretty jolly time with it.
Just wanted to share that I'm having a great day so far, and that I hope you do too! :D -
Holy shit, what a language...
I'm currently learning Java right, I have never seen such a weird language in my life.
My background is Web Developing and some lua here and there. After a while playing around with Kivy and other alternatives to native Android Studio development I decided it was most probably time for me to start actually getting ready for the inevitable Android Studio.
Getting used to the GUI was easy, everything seemed to make sense and I was already used to IntelliJ.
But the issue came from Java, the number of ways that it's broken, just JVM by itself should be enough to condemn this language to eternal doom. Not even talking about the Syntax, coming from JS it was basically Hell.
I get it's more than useful, but seeing its History, Java should've probably stayed at its Oak stage lmao.27 -
Any opions/experience with Lua? Im using this language right now in my internship. Its suprisingly easy, but not as popular as javascript or c#.8
-
I swear all this neovim-lua rage with different distros and crazy setups and never ending plethora of plugins is over the top and adding more clutter than my 2011 Eclipse setup. I can't keep the fuck up with all the changes and updates.
So if I want to add a plugin or a config to my "hand-written" config, I have to look through dozens of distros LazyVim, Kickstart.vim, LunarVim, AstroVim, CrapVim, .... in order to find something that just works ...1 -
In 2011,when i was 12, i was playing Garry's Mod with a couple of friends, and i don't remember the circunstance, but one of my friends said: "I wonder how games i made". I have no idea why i was never curious about this subject before,since i played A LOT of videogames, but this question did stick to my mind, so i decided that i would search about it. Searching, i discovered that Garry's Mod used the Source engine, and that it was made in LUA. Tried LUA. Understood very little. Lost my interest. And then, i would only attempt to program again back in 2015, where i learned C++ in high school. Then i learned SQL, and now learning Java. I also discovered that i LOVE programming, and now i have plans to graduate on CS.
-
My first programming lan was Lua. And they who know that lan knows, that I may was confused when I switched to a 'normal' programming lan like c# or java, because when you init a string you just type: a = ":)". but you can still set it to an int: a = 10. So every vars in Lua aren't sticked to a type. The arrays also can have any kind of var in it.
So I never learned what a String, int, ... is. I didn't understood why a method can't just return anything or why an array has a length.1 -
First contact with code was about 10 years ago, trying to customize my own server of the old Tibia (pre historic mmo game) with lua language
-
The Love2D documentation is so lovely to read, this has been my favourite experience learning a language.1
-
Skein: noun - a type of access modifier, allowing a property to be read internally or externally, but only written to *externally*. See "orwell" for opposite access modifier.
hermit (noun) - an access modifier specifying a property may only be written or read internally.
Gopher (noun) - an access modifier not to be confused with a groundhog.
Blackhole (noun) - can be written to, can never be read. See dev/null for details.
In other news I wrote the basis for a cms in lua.
Because I hate the cloud. -
Is Lua worth learning?
What can be achieved easily with it? What are it's strengths and weaknesses?6 -
I want to learn a scripting language, and can't decide which one.
Python, Ruby, Lua, something completely different ?
I want to hear your opinions.11 -
!rant I've been meaning to learn Python for quite some time.
I've worked with Java, PHP, C, C#, JS, Ruby, even a bit of Lua. Any good books to recommend?3 -
Lua and its goddamn metatables. I love the crap out of lua and its syntax, and metatables are really important, but setting them up is unbelievably confusing.1
-
What programming books do you all recommend?
Language wise any books on C, GoLang, Python, Rust, and LUA are welcome
And topic wise I’m interested in books about computer science theory, network programming, low level programming, and backend programming are welcome.
I know it’s a wide variety of topics but some are stuff Im currently doing, I’ve already messed with and just really want to learn more or focus on, or plan to do it when I get around to it6 -
In highschool I started by setting up an open tibia (OT) server for which I copied and edited lua scripts to create spells and quests. Didn't do anything remotely difficult in those times.
In university I needed to learn and use Prolog. And soon after that I had an OOP course in Java. Didn't really learn Java during that course. And started to accept I would never like real programming.
During a Datastructures course I actually got the hang of java and started to program in my spare time.
Finished the Datastructures course with a good grade which landed me a job as student assistant for a python course.
That job in turn landed me a part-time job as python developer where I learned most of my programming skills.
Now I'm back to working in Java and I still learn everyday. -
I'm trying to pick up game development as a hobby (im already a full stack software engineer) and ive decided to either do lua with roblox or java with minecraft. im going to start out doing mods and building on top of already existant systems and then venture further if i like it. which do you think i should do? lua or java?5
-
I don't "using namespace std;" because it makes my code look more confusing to others and may make them more hesitant to ask questions.8
-
It was game dev.
Just googled how to make games on my own, thats how it began. Yoyo games game maker, Oracle's greenfoot(this was some cool shit),stencyl then using some random game engines, pygame,lua etc. Had fun. Still having fun. Will try game dev again in future.2 -
Hi everyone well we quit gg scripting cause we figured out lua can be converted to cpp for memory searches! we all know lua and know how to convert it to cpp but for the gui
How do i learn java?8 -
LUA is used in Starbound, WoW, in Half Life mods...
I learn Lua making mods for Starbound.
It's useful but nobody likes it :´v6 -
Welcome to the first (and probably only) episode of Code’s Papercuts!
I don’t like Lua. I have almost no experience with it, but in my opinion any programming language where arrays start at 1 should be ashamed of itself.
This has been ~~Brady’s~~ Code’s Papercuts!2 -
I started with programming through a Minecraft mod called Computercraft. You programmed a computer with lua. Some time later I played with python, and then I was hooked. I am a self taught programmer and have tried many different languages since.
-
Started with the old computer craft mod for Minecraft that put Lua into a form I could understand with clear goals (I was 12 or 13 at the time), and from there learned Java and some web dev tools. Now I'm here writing simple compilers to procrastinate uni work
-
I started with a free trial of neobook (anyone remember that?), and then moved on to MS SmallBasic. At some point I had discovered Roblox and was stuck with that and lua for a few years. Eventually I started learning C# from a course, but never really used it much so I kinda forgot it.
School got a lot more busy for me and so I wasn't really able to do much programming for a few years, and even when I did, it was mostly bash and docker stuff. Then in the beginning of last year, I was able to start learning Go, which is now my current language of choice. -
Today after the week and a lesson time in an high-school I got back home and decided to play some sacred 2
I had already installed some mods on it given that I have already finished it years ago and I wanted some challenge.
It ends up that the mods add too much difficulty, so I open up the configuration files of the mod (some sort of Lua tables) and then spend like an hour and half doing some reverse engineering on it to find a middle way between the vanilla and the Uber difficult mod
Wow! -
WOW -__- they left me to code the SPO Teams website when im coding a Text rpg engine while Over clocked is fixing his tablet while Solario is helping his other friends code his java + lua = andlua mod menus for android Screw ya )=<
@overclockedgd
@Solario360
im not even good at website designs LOL its gonna be a website that wants to commit DDoS iill post the final product and if you survive through the whole website without getting your computer molested props to you =)14 -
Was playing some devast.io and it was awesome
[username: Trippy Pepper]
I had a high score around 1000k or so kept being killed constantly and such on downloaded pycharm on mom's pc, downloaded an android emulator as well :) i cant wait to go back to scripting but andlua is just a mix of java and lua
Example: https://youtube.com/watch/...
what do ya think about the high score? -
I am learning Lua because I am developing in a game. My question is would there be a way to load C into Lua6
-
There needs to be a new (MOOC) class for people like me.
Hi, I'm William. I can't get my head around designing systems. I've read GoF and a few breakdowns of it as well. I find some patterns obvious for my field of interest (game dev, woot!) while I'm reading through the stuff, but have a pretty hard time retaining much of it. I'm aware of the danger of over using patterns, so I don't worry that much about it. I'll look something up when I'm sure I need it.
Still, I'm tired of the tutorial blues. I can watch a few different people write entire games, usually not in the language of choice, but that only helps me so much.
How do I fight scope creep? In the meantime, how can I make things extensible? Scope does need to creep some, after all.
People joke about starting with (visual) BASIC ruining you forever. I don't believe in that crap, but is this just denial? Am I too dumb for this? Not that I'd ever seriously blame a language for that.
I've been a hobbyist for well over 10 years, please don't make me count exactly how long I've been unsuccessful.
I'm baffled by Löve. I think it's the coolest shit I've seen, maybe ever (unless we're counting IPFS).
I think what really prompted this rant, apart from the obvious degradation of my mental health, was my search for an entity component system for Löve/Lua. Hold your replies. I know there's a few of them, and I'm positive that they're fantastic. I'd roll my own, but that requires actual Lua specific knowledge that I just haven't dug all that deep into yet. I can't wrap my head around the ones that exist, even though I can tell their complexity is next to none really.
I have severe tool anxiety, I'm shocked that I've stuck with ZeroBrane Studio as long as I have. It feels good though.
Sorry to use this as "Devs Anonymous", but I think that's how this community helps (me) best.
I feel like I should stop now and just say: Advice? before this gets much deeper/less readable. -
I have a class on my college on which we can choose what to do as a final project the only requisite being that we need to do something we haven't covered in any class at the degree.
I want to be a Gameplay programmer and saw that many offers ask for Lua, then I think this is an opportunity to do something in Lua and learn the basics but I don't know what to do, any ideas of a simple project I can do in Lua or a framework that uses Lua that can teach me the basics of it?
Tl;Dr: Want to do a small project in Lua, have no idea what to do tho. Ideas?4 -
I've been doing stuff on my free time after school for about 3 years now. And i cant keep working on projects without losing motivation or getting stuck without a solution and then giving up, i've also tried working with a lot of teams and friends but it seems like everything i do or i work on ends up cancelled or full of issues and roadblocks. any advice?4
-
man that whole lua shit from neovim really went overboard
like seriously, that shit used to be for msgpack/RPC and they've literary made it default then built-in and now the whole fucking remote protocol's silently rotting 🪰 away...
A software fuckup so massive the fucking editor now needs 2 running instances so their "lua kink" can keep going.
No wonder fucking denops was born
----
only thing keeping me there's tree sitter but once that gets inside vim/vim it's byebye fuckers2 -
Lua handles arrays and maps/dictionaries essentially the same way. Makes for a pain when binding to cpp. Shame in an otherwise awesome embedded lang
-
Have i told You i hate lua and lohrawan with a node Red Copy to? And anyway IOT also. Grgrgrgr. And i hate Autokorrektur now3
-
Does anybody have some programming challenges (links or just a guide with rules and restrictions to follow)? I'm bored.2
-
Why is Lua such a pain to install? Like seriously there are so many hoops to jump through, why can't it be like java or python? -_-3
-
Dabbled in primary school on Microsoft Front Page, but actually programming would have been the WoW private server scene. Started on C++, got confused, tried LUA, loved it, came back to C++ was still confused but could get things done. And then the story goes on and on.1
-
! Rant
Recently received my ESP8266 and for bad or for worse quickly flashed it to use thingsSDK and espruino.
I have setup a webserver on it but at the moment you need to go to its local ip to see the page, does any one have tryed this before and overcome to redirect all requests to that page? Any ideas are welcome, i know this can be done easly with LUA but cant code LUA, yet...13 -
Am I going crazy or is this some real nasty looking spaghetti code?
https://github.com/neovim/neovim/...3 -
anybody know any 3rd party YouTube apps that allow for music and no ads? I swear I've seen one but I can't seem to find it11
-
Looking for Starbound modding LUA examples
Download unofficial modding book and found out json examples...1 -
Wtf is this ESP32 shit and it's hype?
I bought one because I thought JS on a microcontroller? That's gotta be fun!
I'm a hobbiest when it comes to MCUs and I do JS as a job, so I tought I'm made for this and I know at least as much as all the kids on the internet doing it.
Nothing makes sense with this shit. You have to flash wildly compiled modules of WHATEVERTHEFUCK with fucken python development-kits which have something to do with Lua to give you some kind of node-REPL which answers you with a bunch of strangely-looking errors starting with "stdin:x:".
If this NODE-MCU shit is made for JS why is there stuff about Lua everywhere you go with this, I don't get a single thing. Now I'm sitting on about 3 different git repos of sdks or what do I know and know less than before.
Oh and there is actually not a single tutorial really targetting the esp32. it's all about that 82xx-model.
Then I start googling around a bit more - It's not even ES6, it's just some ES3/5 shit. Why would you even do this. That's actually harder to manage than classic C/C++. You get no gain with it. Fuck me.
Wtf bro.23 -
Tried Lua for the first time in a while. Really didn't like how it handled chars/strings, that's about it.3
-
Lua/ C
Java/ C
Swift/ Objective C
Visual Basic / C or something
C / C#
……..
👆last reversed yet, that looks like a funny face 😑…
Where, am I?…8 -
Has anyone used or seen a nice lua back end wrapped already in a windows front end programming platform, I have made many apps do many things in a app called AutoPlayMediaStudios, even tho it was made for AutoPlay Menus at first the tools it as and can make are epic but it's getting past it and the support is bad for $300 you get the app at that time and 6 months support and update after that you get NO updates and no real support.
I looking to move forward,there is the option to learn a new language for most people but for me I do it for fun and I just want to be able to keep supporting the tools I already made but in a more updated platform and better windows integration.
I love lua as its 90% if not 100% readable and understandable so when I get a error I can see it easy.
Love to see what other apps might be out there, also I don't want to make overlay apps I want to make core exe's fk MS's overlay bull.
Thanks for reading.1 -
For fucks sake, why can't Microsoft switch to Lua or JS as an embedded language instead of VBA.
It bad enough working with their office-jank but having program in this butt-rape of a language takes the cake.7 -
Seeing as I will be scorned for asking this on SO, and there's a ton of devs here that probably had this conundrum: how have you solved horizontal scrolling when working? I know shift + mw+/- works but what's the use having a mouse with macro functionality if not to simplify that? My current software supports lua scripting (but I don't know how to write it). I see some people requesting this while googling I but cannot find anyone that has a solution. The closest I get is a user requesting it from Logitech as they apparently have the same but for ctrl+mw in their products.10
-
Whoo Hoo!!! one more day till school ends for 2 week christmas break yeee i can finnaly make a mod menu with android studio and apks no importing them with java only overclockedgd is doing that with his andlua, [Java + lua] , While flu and norovirus + corona is coming to be exploding and giving people the chocolate squirts my gf is gonna try to give herself noro so i can spend more time with her and take care of her she did that last 2 years i hope she isnt gonna get it again..last year was hell What are you guys gonna do on christmas break?3
-
Hi everyone hows it going today? been learning alot lately Question? when working with lib2cpp.so files whats the best inspector for them? and what do these files contain? (example: gamelib.so)
i know a .so file is C++ so i think it has something to do with offsets and memory ranges something like that.
but im trying to open one lol
we have moved to andlua and i learned the api fully
app: https://andnixsh.com/2020/05/...
AndLua+ app is a lightweight scripting tool that allows you to easily perform script programming and testing on your Android phone. This is a very useful tool for those who need script (android development or modding) programming. AndLua+ is based on the open source project lua. It uses a simple and beautiful lua language, which simplifies cumbersome Java statements. At the same time, it supports the use of most Android APIs, free installation and debugging, and makes your development on your mobile phone easier and faster. The permission requested is for you to write a program to use, please rest assured to use. -
luasocket decided to provide blocking network primitives to be used in single threaded lua environments. Sure I can overcome it with socket select polling, promises and coroutines. But WTF. It is 2016! Even node.js does it better.
-
I'm gonna need a laptop, and the one I have is too large for my liking. I am just curious as to whether or not I should get a windows laptop and install Ubuntu, or take the extra time to find one with Ubuntu already? Do you guys have any suggestions for laptops around $500?3
-
I want opinions, what should I improve (other than a clickable moon to toggle to night mode)?
I got bored and decided that I would make a "download portal".
https://gyazo.com/2d6f07838d96f9736...