We had two major updates in rapid succession, so I'll be posting them both here.
Tuesday, February 28, 2017
A rather solid but unremarkable week; I feel this week could aptly be described as a lingering shadow of last week. For both better and worse, last week's "I started on" could basically be replaced with "I finished" or "I almost finished," and the log would be nearly complete. Thus, as has been falsely stated many times now,

---
PlateMeshes: 90+% complete in the LT core. As discussed last week, I emphasized building a release-quality implementation since they became an invaluable tool in LTC++. I now have a high-quality, fast, C library implementation of all of the old PM functionality with the exception of rotation of individual plates. I will need to spend a bit more time in order to finish that bit efficiently, but the rest of the work was by far the bulk. Frankly it required more time than I would have liked, but all of that time was spent adding supporting functionality to the core in order to efficiently support a good PM implementation. The good thing about this kind of time is that it's "permanent progress," as is all progress of the LT core (which is, as a reminder, designed to be the 'etched in stone' part of the LT engine).
Mesh 'Warps': 20% complete (I figured out how to do them). These are the things that allowed me to distort models in cool ways that added curvature and interesting global features to ships and stations. Unfortunately, their implementation in C++ using all that fancy (and incredibly-nasty) template stuff I used to do made it fairly easy. I had some trouble figuring out how to do the same thing effectively in a clean, C API (i.e., making it easy to build warping functions from LuaJIT). I've designed the implementation, about which I'm pleased. I haven't coded it yet. Interestingly, solving this design problem brought me insights on how to make reference-counting work cleanly across API boundaries (for example, to enable both the core and LuaJIT to hold pointers to the same object and still have all memory management work correctly). I've not had this insight before, but when the time invariably comes that I need to do this (beyond warps, which will require it from the get-go), I now know how to do it painlessly.
Networking & 'Control Panel': 100%/90% complete (server/client), and completely new to any of the LT engines! Yes, this is where about 2.5 days of my time went this week, but it's a technology investment that I'm betting will pay dividends. While working with planets, it occurred to me that I would really like a UI for changing the procedural algorithm parameters in real-time to see exactly how they're affecting the final result (with complex procedural algorithms it can be very difficult to reason about the effect of individual parameters). I didn't want to spend a huge amount of time building something just for this task, though, so, inspired by a friend at LTP who does web development, I decided to use a tool that already exists and is very fast and easy for creating quick UIs: the modern web browser. This necessitated networking functions in the LT core, which I had promised I would provide for modders who want to attempt 'multiplayer LT' mods anyway. So, I implemented a multi-platform TCP & UDP socket API, then used it from LuaJIT to spin up a very simple HTTP server run by in the background by the engine that serves up a simple control panel webpage when connected to via a browser. It can change internal engine variables automatically in response to controls like sliders or buttons being changed in the panel.
Though I'm hoping the ability to connect to and communicate with the engine via networking will pay substantial dividends over the remaining development time, having the control panel available is already really helpful: I have a really easy way to expose real-time-tweakable parameters, and, as a bonus, since it's based on sockets & HTTP, I can even connect remotely so that I can use one machine (like my tablet) exclusively as my 'controller' while I develop on the other. I'm also thinking this will be great for monitoring and managing long-running universe simulations (when I get to that point, ideally sooner rather than later)! I'd even like to explore using this for asynchronous resource generation on the GPU, which is traditionally difficult to do in a single process (due to threaded GL contexts being messy). There are a whole lot of ways I can envision using even this very basic networking tech


---
In the LTASM world, I did exactly what I had mentioned and hoped for last week: basic x87 floating point operations. Quite happy to have that stuff working. I've got enough to, for example, do most if not all of the basic FP math that you might do in the LT logic, although I don't necessarily have all of the opcodes for doing things in the most efficient way. Frankly, though, my first goal in this world of Plan Z is to have a script -> machine code pipeline working at all. That will be amazing enough for me, then we can worry about micro-optimization. My tests this week with FP instructions in simple loops are already blazingly-fast. I am getting a stronger and stronger feeling that this work will play a role in LT even if LuaJIT continues to hold. In fact, I can see it being a beautiful addition to LJ! LJ is basically a dynamic asm generator, why not have a static asm generator for perf-critical code? Man does it make a difference getting down to that raw level (I mean compared to something like Lua, not C/++).
Speaking of which, as usual, I spent some quality time with the Intel manuals this week, covering chapters 10 & 11 (SSE, SSE2), and skimming 12, 14, & 15, (SSE3/4, AVX/AVX2, AVX512). So basically, I learned a whole lot about vector / 'SIMD' instruction sets this week. Fun as always

---
It's worth mentioning that I spent a good bit of time this week on other, non-coding work. This week saw an abundance of emails, real-life events, and a bit more time spent with the forum than usual. Speaking of which, I assume that most of you have seen the announcement of Talvieno as Community Manager by now, but if not, check it out

---
No, I'm not terribly impressed with this week (maybe I'm just tired right now...looking at the log, it seems fairly substantial?), next week should see less clerical work as well as less of having to finish up things, and more of getting to start new things. Seriously, next week I hope to see ships and stations in their full glory: PlateMeshes at 100% (rotations are definitely needed for stations), mesh warps implemented, procedural algorithms 100% ported, mesh ambient occlusion calculations 100% complete. I'd like to see asteroids as well, meaning scalar field extraction in the C core. If I have all of those things in a week, I'll be happy! I'll also have a good-looking, content-filled system, presumably. On the asm side, perhaps basic SSE functionality; let's say scalar operations at first, so that I can do the equivalent operations that the x87 FPU would do, but using the more-modern SSE (interestingly, the SSE instruction set is not just for vector processing, it has scalar (single-element) instructions as well).
Until some time in the next 7±2 days...!

Link to original: http://forums.ltheory.com/viewtopic.php?f=30&t=5825
Greetings LT forumers!
Those of you who have spent any substantial amount of time here have no doubt encountered Talvieno at some point or another. It's hard not to notice his outstanding and inexhaustible dedication to making the Limit Theory Forums a better place. In fact, it's no secret that a lot of you even wish for him to have more power ('Talv for president!') Well, you've already read the title, so you can guess what's coming

- ...building Taiya, our favorite resident Limit Theory forum & IRC RSS feed bot. For those who don't know Taiya, she's not only a sweetheart of an IRC chat bot with a boatload of neat functions, she's also the toughest forum policewoman in existence. We get hit by, on average, 2-3 new bot registrations a day (which is down a bit from previous months, where it peaked around 15/day). A lot of these bots post spam topics. Taiya shuts them down almost instantly, banning those poor bots of lesser intellect than her and moving the spam to a hidden 'trash' sub-forum where mods and I can look at it later. There's no telling how many bans Taiya has issued, nor how many spam threads she's killed. She's made my life so much easier! Thanks Taiya!
...running the Limit Theory Fan Competition, an awesome idea started way back in the day by the legendary Katorone and re-ignited by none other than Talvieno. The current LTFC ends this Saturday, so check it out if you want to participate (there are prizes!)
...conceiving of and running REKT, an incredibly-impressive forum-based RPG whose main thread ran for 181 pages and over 2700 posts. If you've ever wondered just how intense, creative, and amazing roleplaying on a forum can get, you need only take a peek at the REKT wiki, which is both a triumph of creativity and an inspiration to me. Talvieno informed me that most of the wiki is actually attributed to the hard work of Dinosawer, so hats off to him!
...starting a novel based on the Limit Theory Universe, entitled Small Choices. The existing chapters are, in my opinion, very impressive, even though Talvieno has told me that he feels the same way about Small Choices that I feel about code I wrote a long time agoSadly, he didn't have enough time to devote to the project, so Small Choices has been discontinued in favor of redirecting more effort toward the other three million projects he's got going on
...creating an LT IRC-Based RPG, which is currently under development and whose progress I am keenly interested in following! Talv may just end up creating LT before I do...Seriously, check this one out. It's awesome. Incidentally, the game is played through (and GM'd by) the ever-talented Taiya!
...heading up Hawkspears, an 'LT Community DF Succession Game.' I'll admit that, since I've (regrettably) never sunk time into Dwarf Fortress, I don't really understand what's going on here...but the screenshots are pretty and the whole thing is just one more example of Talvieno starting a creative project that engages and excites the LT community!
...creating and maintaining the Limit Theory Email/RSS News Thread, an aggregation of my 'important' posts since the time when they started to become...scarce. This helpful thread has allowed people to easily track a sometimes-difficult-to-track developer
All of that is on top of his normal moderator duties. Suffice it to say, Talvieno has worked very hard for and has no doubt earned the title of Limit Theory Community Manager. As of a few weeks ago, I offered him the position and he accepted, but we've been keeping it under wraps until I had the chance to make this post. Finally, it's time!
As CM, Talvieno will continue his normal duties as moderator, but will also act as a point-of-contact between me and the LT community & backers, helping me reduce time spent on activities that aren't directly-related to getting Limit Theory out of the door. For example, I was tempted to ask him to write this post and announce his own CMship, as a demonstration of the time that he would be saving me

I wouldn't feel right about this post if I didn't also take a moment to recognize the other LT forum moderators, all of whom have made my life tremendously easier over the course of development. Sincerely, thank you to Bele, DWMagus, Gazz, Grumblesaur, and Just_Ice_Au, our fantastic moderator team. In promoting Talvieno to CM, I absolutely do not want to overlook or belittle the enormous contributions that our other moderators have made to the community! Thank you guys

---
So, without further hesitation, please give it up for Talvieno, now the official Community Manager for Limit Theory!

Link to original: http://forums.ltheory.com/viewtopic.php?f=11&t=5824