<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Melody Soriano on Medium]]></title>
        <description><![CDATA[Stories by Melody Soriano on Medium]]></description>
        <link>https://medium.com/@melodysoriano?source=rss-e88dc7030f28------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*3wbjFTFCpsex55a0-ntUjQ.jpeg</url>
            <title>Stories by Melody Soriano on Medium</title>
            <link>https://medium.com/@melodysoriano?source=rss-e88dc7030f28------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Thu, 19 Nov 2026 06:43:50 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@melodysoriano/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Agile Development Frameworks]]></title>
            <link>https://medium.com/swlh/agiledevelopment-frameworks-8efd9a983507?source=rss-e88dc7030f28------2</link>
            <guid isPermaLink="false">https://medium.com/p/8efd9a983507</guid>
            <category><![CDATA[agile-development]]></category>
            <category><![CDATA[extreme-programming]]></category>
            <category><![CDATA[scrum]]></category>
            <dc:creator><![CDATA[Melody Soriano]]></dc:creator>
            <pubDate>Mon, 21 Dec 2020 03:59:53 GMT</pubDate>
            <atom:updated>2020-12-21T04:01:58.460Z</atom:updated>
            <content:encoded><![CDATA[<h4>What are they and what can they do for your team’s project?</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*dUBDW0utMGIa0H1U" /><figcaption>Photo by <a href="https://unsplash.com/@epicantus?utm_source=medium&amp;utm_medium=referral">Daria Nepriakhina</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><h3>What is Agile?</h3><p>Agile is a framework that focuses on working as a team with a focused goal of building iterative software, insofar as it allows for revisiting previously built components (ie planned reworks), incremental, such that deliverable working software is produced at every interval, and allows for continuous integration of new features. The basics of and the ideas behind the framework can be found more <a href="http://agilemanifesto.org/">here</a>.</p><p>There are many different agile-based frameworks, but they all have the same basic principles. I’ll go over the absolute basics of the two most common frameworks: scrum and extreme programming.</p><h3>Scrum</h3><p>Scrum is a subset of agile, and the most popular agile framework. It revolves around timed Sprints, usually from one week to one month. Each sprint begins with a planning call that details the product backlog items that will be tackled during the sprint, as well as agree on the scope of work that can be covered.</p><p>At the end of the sprint, a sprint review and retrospective will take place. During the review, the team covers which items in the sprint were completed and which items were not, then demoing the complete work to product owners or stakeholders. Afterward, the team collaborates with the product owners on what to work on next.</p><p>During the retrospective, the team comes together with the leader aka Scrum Master, and breaks down what happened as such: what went well during the sprint? What didn&#39;t go well? What can be improved for better productivity during the next sprint?</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/998/1*gD2r_qSLAo-05vJ8t-PD3Q.png" /><figcaption>the subway map to agile practices source:<a href="https://www.agilealliance.org/agile101/subway-map-to-agile-practices/">https://www.agilealliance.org/agile101/subway-map-to-agile-practices/</a></figcaption></figure><p>More frequently will be scrum meetings or stand-ups, usually daily, where team members will get together and talk about the progress they’ve made since the last scrum, what they’re planning to do until the next scrum, and speak about any issues that are blocking them from continuing.</p><h3>Extreme Programming</h3><p>Extreme Programming, shortened to XP, is another agile framework, that is almost as complicated as it sounds by the name and I will attempt to give a brief explanation of some of the practices. Twelve core practices are described in more detail <a href="https://ronjeffries.com/xprog/what-is-extreme-programming/">here</a>.</p><p>In XP, everyone is apart of the whole team, which forms around a business representative known as the Customer. It is highly encouraged for all members to be co-located in one space or office. Every iteration the team delivers running, tested software to the customer, who then can use that software for any purpose, including release to end-users.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/720/1*NBgHJkYhdmVOsghB0pLeLA.jpeg" /></figure><p>The planning game addresses two concerns in software development: predicting what will be accomplished by the next due date and determining what to do next. There are two steps in planning that help emphasize steering the product, rather than predicting exactly what is needed and how long it takes. <em>Release Planning</em> is a practice where the Customer presents the desired features to the programmers, and the programmers estimate their difficulty. <em>Iteration Planning</em> is the practice whereby the team is given direction every couple of weeks. The Customer defines what it means for a feature to be complete, and the programmers build automated tests to prove that a feature is working as expected.</p><p>One of the big things that set XP apart from death march or crunch development is the dedication to a sustainable pace: team members work overtime when it is effective, but normally work in such a way as to maximize productivity week in and week out. Crunch seldom produces quality software, though certain sectors of the tech industry have yet to really figure this out (CD Projekt, I’m looking at you).</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8efd9a983507" width="1" height="1" alt=""><hr><p><a href="https://medium.com/swlh/agiledevelopment-frameworks-8efd9a983507">Agile Development Frameworks</a> was originally published in <a href="https://medium.com/swlh">The Startup</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Object-Oriented Programming]]></title>
            <link>https://blog.devgenius.io/object-oriented-programming-f0107bf139c8?source=rss-e88dc7030f28------2</link>
            <guid isPermaLink="false">https://medium.com/p/f0107bf139c8</guid>
            <category><![CDATA[object-oriented]]></category>
            <category><![CDATA[c-sharp-programming]]></category>
            <category><![CDATA[programming]]></category>
            <dc:creator><![CDATA[Melody Soriano]]></dc:creator>
            <pubDate>Mon, 14 Dec 2020 04:39:10 GMT</pubDate>
            <atom:updated>2020-12-14T09:42:31.259Z</atom:updated>
            <content:encoded><![CDATA[<h4>Examples and Cats</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/557/1*89HoghjlnoNHzNSwDVdYDg.png" /><figcaption>from the basics to the pillars</figcaption></figure><p><em>Object-oriented programming (OOP)</em> is a programming paradigm that allows you to keep similar data together, and give the ability to modify that data while keeping the details hidden away in a so-called black box. This makes it possible to create code that is modular, easy to maintain, and abstract, which is particularly useful when you create larger programs. Sounds nice, right? Let’s go through some of the most important concepts in OOP. I’ll be using C# for the examples here, but the principles apply to almost any object-oriented programming language you can pick up.</p><p>Let’s start at the very beginning. The first concept to think about is objects and classes. There are two ways that I personally like to think about objects: as a bucket of variables and functions (or methods) and also as an <em>instance</em> of a class. Now, if an object is one specific thing, then a class would be the category that thing belongs to. Consider this: I have two cats, Marble and Cookie. They are… decidedly not the same cat, but they are both cats nonetheless.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*GMutC1UzInkKe5EHWuHDRg.jpeg" /><figcaption>Marble (left) and Cookie (right) {follow on insta @ marblecakethecat}</figcaption></figure><p>In this example, the class would be Cat, and the instances of that class, a.k.a objects would be the two cats Marble and Cookie. If we suppose that the class Cat has attributes (variables in its bucket) of name and age, this would look like so in code:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/710/1*8KjxcMisZ-aZGgeTbMhgWg.png" /></figure><p>There’s a lot of stuff up there that we don’t need to worry about right this minute. The most important part of the snip above is the lines that start with Cat. There, we are creating two variables of type Cat that are called marble and cookie, and we are setting their respective names and ages. Then for funsies, we can write both of their names out to the console! Let’s take a look at the Cat class and see what we can get out of it.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/519/1*FwCW1ZEgsjcZ9eN_dsjfDg.png" /></figure><p>Okay, on the left we have a lot of fun things we can look at here! The first thing you should notice is the fancy colon after the class name Cat. This, in C#, tells us that the Cat class is inheriting from the Animal class. What does that mean? Well for one, notice that age and name aren’t defined here in Cat. That’s because they are attributes that Cat is <em>inheriting</em> from its parent Animal. We also haven’t explicitly defined Set/GetAge or Set/GetName here, because they belong to Animal also.</p><p>Now, what’s up with this Set/Get nonsense? We have it for our breed attribute as well! Why can’t we just access our variable directly? We can’t do that because of the fancy <em>private </em>keyword in front of our variable name. These <em>access specifiers </em>are how C# implements the second principle we’re touching on today: encapsulation! This is the process of enclosing our variables within a logical package. Our class is public because I’m accessing it from another project within my solution. Our instance variables are private as is best practice, and then accessed /changed with getters and setters. I could, for instance, make the breed variable read-only, in other words, I could delete the setter method.</p><p>Encapsulation here is working hand in hand to <em>abstract</em> our data and put it more or less in a need-to-know situation. Abstraction here also allows us to have our classes act as a black box of sorts, letting us use them, without us needing to know how the inner workings of our class actually function.</p><p>The last fun thing you can notice is that we have two constructors for our cat class, one with two required attributes and one optional, and one constructor with no attributes required. This is a great example of the last principle we’ll cover in this article, <em>polymorphism</em>. Polymorphism allows us to have multiple functions with the same name that take in different types of arguments or different numbers of arguments or even do totally different things!</p><p>Well, there you have it. Object-oriented programming more or less in a nutshell. I will leave you with the fun little console app I ended on with this class:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1017/1*oueSNo-eeU_bm5XaLxIOTA.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f0107bf139c8" width="1" height="1" alt=""><hr><p><a href="https://blog.devgenius.io/object-oriented-programming-f0107bf139c8">Object-Oriented Programming</a> was originally published in <a href="https://blog.devgenius.io/">Dev Genius</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[What I Learned Making Games in Unity]]></title>
            <link>https://blog.devgenius.io/what-i-learned-making-games-in-unity-3936075af5b8?source=rss-e88dc7030f28------2</link>
            <guid isPermaLink="false">https://medium.com/p/3936075af5b8</guid>
            <category><![CDATA[game-development]]></category>
            <category><![CDATA[c-sharp-programming]]></category>
            <dc:creator><![CDATA[Melody Soriano]]></dc:creator>
            <pubDate>Sun, 06 Dec 2020 18:14:37 GMT</pubDate>
            <atom:updated>2020-12-06T19:06:15.777Z</atom:updated>
            <content:encoded><![CDATA[<h4>Or, why you should learn C#</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*7JoIZX9M1wp-CS8q" /><figcaption>Photo by <a href="https://unsplash.com/@sharkovski?utm_source=medium&amp;utm_medium=referral">Kirill Sharkovski</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>Making games, and writing C# scripts in Unity is a lot like doing other types of coding, with a bunch of visual fun stuff plopped on top. It is definitely hard, but it’s hard fun. The Unity3D editor itself has lots of built-in tools for easy prototyping, like programmer-art style graphics with simple blocks with smooth matte textures and ready-made physics materials to get things attracted to the floor or bouncing around. But if you want those little blocks to move or to do anything interesting, you’ll need C# scripts.</p><p>C# is syntactically similar to C++ but with a garbage collector like Java. The creator of C# also created TypeScript, which is a strongly-typed extension of JavaScript that adds advanced object-orientation features like classes and objects. C# is also maintained by Microsoft and was built from the ground up to be open-source and fully cross-platform compatible. Also, since Unity is built on Microsoft’s .NET framework, by writing scripts for Unity, you’ll be learning tools that you can use in many other contexts.</p><p>But let’s get back to business. What good am I doing learning Unity? For starters, because it’s something that is fun for the most part, it’s a really good introduction to programming for people who are a little bit more on the scripting-nervous side. Everything placed in the world is an object and is visually represented in the Hierarchy. You can create objects with parent-child relationships for either functional or organizational purposes. This is done either by dragging and dropping or by changing the object&#39;s parent through code.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ub0X2BMaEsEiIC0VnKeZaw.png" /><figcaption>Editor Windows and Fully-Expanded Hierarchy of an Arcade-Style ball-rolling game</figcaption></figure><p>The only thing you have to keep in mind when changing the parent of a GameObject is that the object&#39;s position (or transform component) will be with respect to the parent object. So if you don’t want your programmer art rolling off the screen, you will need to set the parent&#39;s position to 0,0,0 in the world (also known as resetting the transform component of the GameObject). The only time this wouldn&#39;t be the case would be if you actually do want two objects to always be moving only in relation to each other, like if you were simulating the Earth going around the Sun, and the Moon going around the Earth, in which case the Moon would be a child object of the Earth, while the Earth rotates around the sun, as shown in the hierarchy below:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*NizfTJShYaBt-DqPAGqBMg.png" /><figcaption>The moon is shown as the earth’s child, so it always moves in relation to it</figcaption></figure><p>You can get into a lot of trouble with this stuff if you’re too heavy-handed, however. Take the hierarchy in the rolling ball game in the first picture: we want the camera to follow the ball around the arena, so it makes sense to just have it as a child right? Wrong! If we set the camera as a child of a ball that is rolling around, guess what the camera is going to do: end up rolling around the ball, very rarely showing us what we want to see! Not good. What do we need to do then? Add a script! This script, called SmoothFollow, is a part of the Unity Standard Assets package, which is horrendously out of date and needed a code snipped in one spot updated and I can go through that in the future if anyone needs. However, this script works just fine for what we need.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/854/1*eVAP1rkznrw-LBojafbVTw.png" /><figcaption>Code Snippet in question</figcaption></figure><p>In the snip above, we have the LateUpdate method, which is called once per frame (React lifecycle methods, anyone?). We’re using LateUpdate here because the Update function of our ball controller, is what is making the ball move, and we want our camera to change after the ball moves. The eulerAngles.y is getting the y component of the object’s rotation component (in wantedRotationAngle it&#39;s looking at the target, whereas in currentRotationAngle it’s looking at the camera’s transform). We then use the wanted height and rotation to dampen/update the camera&#39;s current height and rotation, and then we move the camera to the desired x-z distance from the ball. This looks complicated to understand, but the Unity engine here is doing more or less all of the more complicated matrix transformations that would otherwise be necessary to do something like this from scratch.</p><p>And there you have it! I may have not convinced you to learn C# yourself, but I for one learned a lot by playing around and making little games in Unity.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3936075af5b8" width="1" height="1" alt=""><hr><p><a href="https://blog.devgenius.io/what-i-learned-making-games-in-unity-3936075af5b8">What I Learned Making Games in Unity</a> was originally published in <a href="https://blog.devgenius.io/">Dev Genius</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Parallel Computing and the Future of Web Development]]></title>
            <link>https://blog.devgenius.io/parallel-computing-and-the-future-of-web-development-4af659cac155?source=rss-e88dc7030f28------2</link>
            <guid isPermaLink="false">https://medium.com/p/4af659cac155</guid>
            <dc:creator><![CDATA[Melody Soriano]]></dc:creator>
            <pubDate>Wed, 09 Sep 2020 05:41:27 GMT</pubDate>
            <atom:updated>2020-09-09T17:03:54.980Z</atom:updated>
            <content:encoded><![CDATA[<h4>Web Development, Workers, and Looking Toward the Future</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*QoxqLiTR5WmK9Cfn" /><figcaption>Photo by <a href="https://unsplash.com/@ocollet?utm_source=medium&amp;utm_medium=referral">Olivier Collet</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>In the beginning, every program only existed in a single thread, only ever able to execute one instruction at a time. Most processor manufacturers made their processing power better by increasing the clock speed and adding more transistors. But there was one fatal flaw: the faster the clock speed, the harder it is to keep your processor cool, due to the death of Dennard Scaling (more on that <a href="https://en.wikipedia.org/wiki/Dennard_scaling">here</a>, but it’s more or less a theory that states that the less space your transistors take up, the less power they consume) in the mid-2000s. Hence why now in 2020, top-of-the-line processors still run around 3.0–3.5GHz clock speed. Enter multi-core processors and parallel computing</p><p>Parallel computing is something that has existed (albeit theoretically) in the programming world since 2001 since IBM introduced the POWER 4 processer. AMD released the first commercial dual-core processer in 2005 with Intel following with the Core 2 Duo in early 2006. Where am I going with this? Parallel computing is the future, and I am here to help you get in on it.</p><p>But wait, I hear you say, you are nothing but a web developer and javascript is nothing but a lowly single-threaded programming language! I do concede that as someone who does a lot of web development currently, javascript isn’t exactly the best playground for testing and learning parallel algorithms. However, that may not always be the case.</p><p>A few things are floating around to make web development more parallel. The first I’m going to mention here is the Worker. in javascript, you can use a worker to implement a snippet of code in a separate process from your main thread. That way things that you don’t need the answer to right away, that would normally freeze your DOM, can go into a worker. Something like turning an object into JSON normally freezes the DOM and would add up if your application has lots of similar requests. This is the kind of thing that you can offload onto a worker. Another thing is if you are making fetches that require you to do a lot of calculations with the response data is the kind of thing that is good to take off of your main thread.</p><p>You can read more about workers <a href="https://developer.mozilla.org/en-US/docs/Web/API/Web_Workers_API/Using_web_workers">here</a>, but the basic idea is to create a worker object, send the worker a message, the worker receives the message and processes it while the main thread still deals with various elements of DOM manipulation, etc. When the worker finishes with its task it sends the response to the main thread and the main thread now takes that information and deals with that at that point. This, however, barely scratches the surface of parallel computing.</p><p>The main parallel method I’m going to be looking at here is SIMD or Single Instruction, Multiple Data. This entails the computer’s multiple processors or threads computing the same instruction on different data sets at the same time and then combining them at the end. This is the method employed by the experimental parallel browser written about in <a href="https://www.usenix.org/legacy/event/hotpar09/tech/full_papers/jones/jones.pdf">this paper</a>, proposed as a solution for optimizing browser performance on mobile devices.</p><figure><img alt="Diagram for SIMD processing showing the control unit and the multiple processors that an instruction is sent through" src="https://cdn-images-1.medium.com/max/1024/1*HbziV2CDQqqS2h5nFMu3UA.png" /><figcaption>Diagram for SIMD Processing</figcaption></figure><p>Now, there won’t be time to do in-depth algorithmic analysis on every parallel algorithm out there, but one good example of a SIMD algorithm is Mesh Network matrix multiplication. A mesh topology is essentially a matrix, as it’s defined by several nodes arranged in a grid, with no gaps or empty spaces. You can evaluate a mesh network based on two factors; diameter — the longest distance between two nodes, and bisection width — the minimum number of edges needed to be removed to divide a matrix in half.</p><p>The matrices are staggered such that every process gets elements to multiply at all times, multiply all such elements, and then sum the results. This results in pseudo-code like:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lOI9SYRKDIh7I85SJ1rgpw.png" /></figure><p>Now, I’m not going to pretend I fully understand this myself, but if you’re curious, I suggest <a href="https://www.tutorialspoint.com/parallel_algorithm/parallel_algorithm_quick_guide.htm">checking this guide out</a>. It looks daunting at first, but in reality, it’s a good opportunity to read the word hypercube in context multiple times within a single webpage.</p><p>Parallelism can have both practical and theoretical applications that can make an impact on all of our careers in tech if we let it. And perhaps even if we don’t.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4af659cac155" width="1" height="1" alt=""><hr><p><a href="https://blog.devgenius.io/parallel-computing-and-the-future-of-web-development-4af659cac155">Parallel Computing and the Future of Web Development</a> was originally published in <a href="https://blog.devgenius.io/">Dev Genius</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Memory Management and Garbage Collection]]></title>
            <link>https://blog.devgenius.io/memory-management-and-garbage-collection-3b9660ccf7ba?source=rss-e88dc7030f28------2</link>
            <guid isPermaLink="false">https://medium.com/p/3b9660ccf7ba</guid>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[memory-management]]></category>
            <category><![CDATA[garbage-collection]]></category>
            <dc:creator><![CDATA[Melody Soriano]]></dc:creator>
            <pubDate>Mon, 27 Jul 2020 02:43:39 GMT</pubDate>
            <atom:updated>2020-07-27T19:00:25.365Z</atom:updated>
            <content:encoded><![CDATA[<h4>How JavaScript Turns Complex Memory Management into Magic</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*JXf9AOZbZUPWomYz" /><figcaption>Photo by <a href="https://unsplash.com/@loravisuals?utm_source=medium&amp;utm_medium=referral">L O R A</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>In programming languages like C and C++, there are two types of memory allocation: static and dynamic. Static memory allocation is what happens when we create a global or local variable with a single fixed size. The program allocates once when the program is started and never frees it until the application ends execution. Examples in C and C++ include typed variables and arrays. The other type is dynamic memory allocation. We can create these ‘objects’ with any size using malloc(), and the number of bytes they contain can be altered during runtime using realloc(). We can free the memory things allocated this way manually using free().</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/879/1*xxe8V-CC7ewyO9xMl6sGRQ.png" /><figcaption>an example of what dynamic memory allocation looks like in C</figcaption></figure><p>These things can create unforeseen memory leaks as well as complications, like the need to know the difference between a variable(static) and a pointer (dynamic) or between an array (fixed length) and a linked list (with a size that can change dynamically). People have been using C and C++ both for a very long time, and these languages are probably not going away any time soon, but fortunately, many languages today abstract these concepts away from the programmer.</p><p>Languages like Java, C#, JavaScript, and Ruby abstract away all of these things away from the programmer using a system known as Garbage Collection. There are a few approaches that the collector like the one in JS uses. Still, the basic idea is something called the Memory Cycle: we allocate the memory, the program uses that memory, and then when the memory is not needed anymore, the garbage collector frees that memory.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*U9F1Bv9VoQnEJY0xHDxzkg.png" /><figcaption>Memory Life Cycle</figcaption></figure><p>JavaScript allocates memory automatically when a variable, object, or function gets created. The garbage collector looks for a good reason to free this memory during runtime, and there are a couple of algorithms that can help to achieve this goal.</p><h3>Reference Counting Garbage Collection</h3><p>Reference-counting garbage collection is the most naive approach to garbage collection. It checks not so much whether an object is still needed, but whether or not any other variables or objects contain a reference to it. An item is determined to be ‘garbage’ and collected if the number of references to that object is zero.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/851/1*4MzICp5gSgzIcLPkWP9yLA.png" /><figcaption>example 1</figcaption></figure><p>There are limitations to this method, however. If we create two variables in a function’s scope and set one of their properties equal to the other object. When we call the function, the program allocates memory for both objects. Still, since they are circularly referenced, i.e., they reference each other, a garbage collector working with a reference counting algorithm will not mark these objects as garbage because they still have references, even though the program leaves the scope of the function! We have a problem now if we call a function like this many many times, this is a massive memory leak!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/853/1*YyU7FiIU8XtGB6VR2aGJfw.png" /><figcaption>example 2 — circular reference</figcaption></figure><h3>Mark-and-Sweep Algorithm</h3><p>The second, smarter algorithm, is known as Mark-and-Sweep. Instead of naively counting simple references to an object or variable, mark and sweep will instead free memory once the variable is unreachable, like in the case of our second circularly referenced variables. As the name suggests, this is a two-pass algorithm that first marks objects for deletion and then ‘sweeps away’ the memory in the second pass.</p><p>The central concept here is <em>reachability. </em>There are a set of variables that are reachable by definition and which garbage collection will not delete: root variables. These include variables/parameters local to the current function, variables/parameters for other functions in the existing chain of function calls, and global variables. A non-root variable is reachable if there is a reference to it by any of the root variables. This way, once a variable falls out of scope, it is no longer a root variable and is marked for garbage collection.</p><p>In conclusion, even though we have no control over how and when memory gets allocated/freed in higher-level languages, the magic of garbage collection gives programmers one less thing to worry about, even if it is just in a minor way.</p><h4>Sources:</h4><ul><li><a href="https://dzone.com/articles/memory-management-and-garbage-collection-in-javasc">Memory Management and Garbage Collection in JavaScript - DZone Web Dev</a></li><li><a href="https://javascript.info/garbage-collection">Garbage collection</a></li><li><a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Memory_Management">Memory management - JavaScript | MDN</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3b9660ccf7ba" width="1" height="1" alt=""><hr><p><a href="https://blog.devgenius.io/memory-management-and-garbage-collection-3b9660ccf7ba">Memory Management and Garbage Collection</a> was originally published in <a href="https://blog.devgenius.io/">Dev Genius</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Technology, Nostalgia, and Neopets]]></title>
            <link>https://melodysoriano.medium.com/technology-nostalgia-and-neopets-bd5ec11508dd?source=rss-e88dc7030f28------2</link>
            <guid isPermaLink="false">https://medium.com/p/bd5ec11508dd</guid>
            <category><![CDATA[archiving-digital-content]]></category>
            <category><![CDATA[web-archiving]]></category>
            <category><![CDATA[neopets]]></category>
            <category><![CDATA[internet]]></category>
            <category><![CDATA[video-game-history]]></category>
            <dc:creator><![CDATA[Melody Soriano]]></dc:creator>
            <pubDate>Wed, 08 Jul 2020 03:13:08 GMT</pubDate>
            <atom:updated>2020-07-08T03:13:08.083Z</atom:updated>
            <content:encoded><![CDATA[<h4>The Impact of Technology on History and Archiving</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*S0faaukvj_pZKJOMoZfQtA.jpeg" /><figcaption>credit: Neopets</figcaption></figure><p>Technology, and the speed at which it improves, undoubtedly impacts our view of recent history. The first iPhone was unveiled in 2007 (do you feel old yet?) and was an absolute marvel for its time. See my phrasing there: “for its time”! Now, more than ever, it’s so easy to view something little more than a decade old as archaic and outdated. We like to think we’re good at remembering, but how many people know their best friend’s phone number without looking it up? Granted, there are some things that our phones, computers, and servers are better at remembering than we are. What place can nostalgia have in a landscape that changes so rapidly, especially in one like the web?</p><p>The internet is an amazing, wonderful, and ofttimes terrible place. Yet, despite the advice of our parents, what we put out there does not last forever. As a disclaimer, I still recommend caution despite this, but otherwise: servers shut down, websites become defunct or inactive, and entire technologies that make things work become obsolete. Nothing is more representative of this than Neopets and Adobe Flash.</p><figure><img alt="screenshot of neopets showing the lack of functionality of the interactive map" src="https://cdn-images-1.medium.com/max/1024/1*wuwh-PTW0hN0KXZ__L0O1A.png" /><figcaption>The Interactive Map Doesn’t Show on Chrome Anymore, and yes I made a Neopets account for this article</figcaption></figure><p>For the uninitiated, <a href="https://docs.microsoft.com/en-us/lifecycle/announcements/adobe-flash-end-of-support">Adobe is ending support of Flash at the end of the year</a>, and Chrome removing support along with them. Neopets, on the other hand, is a colorful, 20-year-old website about raising cartoon fantasy pets and playing minigames with them. The website holds a place near and dear to the hearts of many people who grew up on the early internet. It also runs almost entirely on Flash. From the interactive maps to Neopet customization to minigames and some locales being completely inaccessible without flash, the entire site relies on it. Although the team announced a mobile-friendly beta back at the beginning of June, progress is understandably slow and probably won’t be even close representative of the full Neopets experience by the time Flash support finally goes by the wayside.</p><p>This brings me to the real meat and potatoes (sorry vegan &amp; paleo friends) of the discussion. What role, if any, should we be playing in archiving or preserving the history of technology, games, and the internet? Neopets is not the first website or game to no longer have a usable experience, even for archive purposes, and it certainly won’t be the last. A recent example in the game sphere is the game <a href="https://www.pcgamer.com/duelyst-to-shut-down-servers-forever/">Duelyst</a> which shut down its servers permanently last February. E.T. the game, a game which was so bad, Atari tried (they <a href="https://www.rollingstone.com/culture/culture-news/unearthed-e-t-atari-games-sell-for-108000-at-auction-46248/">failed</a>) to destroy every existing copy. (The imagery alone of burying 1000’s of copies of a product in the desert is alone enough to make me giggle) What happens 10–15 years from now when Facebook or Twitter’s servers shut down? (if they haven’t taken over the world and created a hyper-capitalist dystopia).</p><p>Another example is the former novella/puzzle website <a href="https://thisisnottom.com/">this is not tom</a>. Originally a series of puzzles that could, realistically, only be solved through crowdsourcing that evolved into a novella that was unlocked via these puzzles; some of the puzzles are now just completely unsolvable because they require digging through the HTML of a Youtube channel sometime between 2008 and 2009 before channel design became optimized for mobile as well as web. The URL for this is not tom had expired and was purchased by fans of the project to host the finished novella as well as the walkthrough for the puzzles when they were solvable.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mngxxE2PRX0LmthuBSLMQw.png" /><figcaption>A snippet of the first unlockable page of the ThisIsNotTom novella</figcaption></figure><p>Believe it or not, there are projects and non-profit organizations that are dedicated to this very problem. Internet Archive has the <a href="http://web.archive.org/">Wayback Machine</a> which was launched in 2001 to address the problem of website content vanishing whenever it gets changed or shut down. Including archives that go back to 1996, it allows a user to “go back in time” and view web pages as they existed in the past (if the website has an existing archive from that period), kind of like a digital library. An article originally published in <a href="https://web.archive.org/web/20120403042627/http://www.uibk.ac.at/voeb/texte/kahle.html">Scientific American</a> (ironically no longer <a href="http://uibk.ac.at/voeb/texte/kahle.html">hosted on their website</a>), goes more into depth about the specifics of how the service functions, (circa 1997).</p><figure><img alt="screenshot of the landing page for the wayback machine" src="https://cdn-images-1.medium.com/max/1024/1*bEttPK1B0CXwxahepYfyGQ.png" /><figcaption>The Wayback Machine Landing Page as it Exists Now</figcaption></figure><p>This actually provides somewhat of a solution to the problem earlier. Not only is the original ThisIsNotTom archived on Wayback, the YouTube channel, as it existed at the time is also more or less intact. It is admittedly interesting to see what youtube looked like in 2009, but it’s fair to say this is far from comprehensive. And that’s fine! Not every website that has been made since 1997 is a historical relic that needs to be saved for posterity, nor would we want it to be. But with Neopets and ThisIsNotTom, there are some things I would be sad to see go.</p><p>In the games technology sphere, the gaming archival foundations such as the <a href="https://gamehistory.org/">Video Game History Foundation</a> as well as the <a href="https://themade.org/">Museum of Art and Digital Entertainment</a> are at work making sure games aren’t lost to the annals of history, saving pieces of hardware and software for games in their collections and galleries, including high quality, lossless scans of packaging, playable binary code of games, and fully functioning servers for <a href="https://www.wired.com/2014/10/restoring-habitat/">long-deceased online games</a>. They, as well as others doing work in similar areas, have encountered copyright issues for their work, especially in the realm of online games, such as MMORPGs (or massively multiplayer online role-playing games) and other games that require consistent servers to stay playable, although the US Library of Congress <a href="https://massivelyop.com/2018/10/26/us-copyright-office-grants-dmca-exception-for-preserving-online-games/">granted a DMCA exception for preserving online games</a> back in 2018.</p><p>But what can we do for Neopets, that flashy, Flash-driven website of my childhood? Well with an HTML-5 update in the works as well as a mobile app on the way, all I can do is sit back, wait, and hope that the core experience will be preserved. That and the fansite <a href="http://www.jellyneo.net/">JellyNeo</a> and its users working to archive the comics, in-universe newspapers, and other things unlikely to make the jump to HTML-5 before people lose access to those things forever.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/200/1*RjxBKllC14-7GI2VvLdC2g.png" /><figcaption>Wocky is pretty iconic, no?</figcaption></figure><p>For my part, I just want to be able to take care of my Wocky, play some good ole fashioned minigames, eat free eggs from a giant omelet, and for goodness sake, let me visit Lutari Island! Although, maybe they should switch to https first…</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=bd5ec11508dd" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Game Development in Ruby Using Gosu]]></title>
            <link>https://blog.devgenius.io/game-development-in-ruby-using-gosu-6a16beca3128?source=rss-e88dc7030f28------2</link>
            <guid isPermaLink="false">https://medium.com/p/6a16beca3128</guid>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[rubygems]]></category>
            <category><![CDATA[ruby]]></category>
            <category><![CDATA[game-development]]></category>
            <dc:creator><![CDATA[Melody Soriano]]></dc:creator>
            <pubDate>Sun, 14 Jun 2020 04:24:03 GMT</pubDate>
            <atom:updated>2020-06-30T15:27:04.075Z</atom:updated>
            <content:encoded><![CDATA[<h4>Part 1: Should I Even Bother?</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*hy1xQIPHGNA82qX1" /><figcaption>Photo by <a href="https://unsplash.com/@joshuafuller?utm_source=medium&amp;utm_medium=referral">Joshua Fuller</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>Unsurprisingly, there are a lot of challenges that come with development. Even with my admittedly short foray into development through my CS minor, analyzing data with Python for physics labs, and now my term at Flatiron, I am able to see just the tip of this iceberg. Even more unsurprisingly, game development in particular has a reputation for being a particularly tough nut to crack, especially on one’s own. It is altogether too easy to overestimate the scope of what a single person can make: not everyone can be <a href="http://undertale.com/">Toby Fox</a>. What I am going to attempt with this blog series (yes I am planning on making this a series) is to explore the very first steps when trying to make games and share every ounce of blood, sweat, and tears on the way.</p><h3>Part One: Should I Even Bother?</h3><p>What, I hear you asking, is someone looking to possibly crack into game development doing in a web development software engineering immersive? Well, everyone has to start somewhere, and for me, my starting place is barely knowing how to code. Game development, unsurprisingly, is a complicated beast, one that has even the most experienced developers floundering. What hope, then, do I: a mere development noob, have in conquering this beast? Well, surprisingly, in my many many minutes of research(insert laughter here) it seems that there may be hope for me yet.</p><p>Step 1: Keep it Simple, Stupid</p><p>If you want to make games: go make a game! The first step to that is not planning the classes in your large scale, massively multiplayer online role-playing game. It’s … learning how to code. When it comes to any complicated software, language familiarity goes a loooonng way, and when learning a language you don’t start out making <a href="https://playoverwatch.com/en-us/">Overwatch</a>, you start out making Tic-Tac-Toe (or chess if you’re especially ambitious). However, even with something that “small” (you’d be surprised at how complicated even something that simple can get) it is helpful to know how to code FIRST. As someone eloquently put in on Reddit:</p><blockquote>Shitty code is shitty code. If you’re a shitty web dev who doesn’t follow standards/practices/good code style then you’ll be a shitty game dev who doesn’t follow good standards/practices/good code style… you know? <a href="https://www.reddit.com/r/gamedev/comments/52cr1i/has_anyone_here_successfully_made_the_jump_from/d7jaxmn?utm_source=share&amp;utm_medium=web2x">[1]</a></blockquote><p>And if you don’t know how to code at ALL, then it helps to start with a simple, easy to read, easy to understand language. What better language to learn the basics of game programming than PYTH- *cough* I mean RUBY? It just so happens that there ARE resources for learning game programming with Ruby. Let’s start with a simple Google search.</p><figure><img alt="Google search window with the text “learn game programming with ruby”" src="https://cdn-images-1.medium.com/max/1024/1*rhKI8NXuK3bzSJMJsZ-k9Q.png" /><figcaption>How to google search: step 1</figcaption></figure><p>Step 2: Look for Resources!</p><p>Okay, let’s go!</p><figure><img alt="The google book thumbnail for Learn Game Programming with Ruby: Bring Your Ideas to Life with Gosu" src="https://cdn-images-1.medium.com/max/1024/1*8o3pz3-ZupMEiNcUYQCP3w.png" /><figcaption>Looks like this could be a good resource!</figcaption></figure><p>Wow! First result, this is going to be easy peasy. Let’s see if we can find it somewhere.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PBzRdAalRW0XkQsMeFQOmQ.png" /><figcaption>Uh oh</figcaption></figure><p>… Oh. It looks like this is gonna take a bit more than we thought, as we are still under lockdown so I can’t go scrounging around local bookstores and I will certainly never advocate flying under a certain black flag, so this trail goes dead for now until I feel like trying e-bay or something like that later.</p><p>Oh! I remember seeing a video of a keynote speech from the 2014 LA Ruby Conference about writing games with Ruby. (It’s a great talk, by the way, I really recommend checking it out <a href="https://www.youtube.com/watch?v=jJhbpY70miE&amp;feature=emb_title">here</a>) It seems like he has a blog where he talks a teeny bit more about it <a href="https://blowmage.com/2015/04/17/writing-games-ruby">[2]</a> and recommends a book by Tomas Varaneckas called <em>Developing Games With Ruby: For Those Who Write Code For A Living, </em>which you can pick up <a href="https://leanpub.com/developing-games-with-ruby">here</a> or, amazingly read for free (legally) <a href="https://leanpub.com/developing-games-with-ruby/read">here</a>. Here we are, someplace concrete to start.</p><p>Step 3: Finally Getting Started</p><p>The first couple sections of the cover setup really extensively, give recommendations for image editors as well as open-source art libraries for making the small proof of concept he is going for. The first thing we’re going to do is get a sneak peek of what the Gosu gem is capable of! Let’s go through the first book example:</p><pre>1 require &#39;gosu&#39;<br> 2 <br> 3 class GameWindow &lt; Gosu::Window<br> 4   def initialize(width=320, height=240, fullscreen=false)<br> 5     super<br> 6     self.caption = &#39;Hello&#39;<br> 7     @message = Gosu::Image.from_text(<br> 8       self, &#39;Hello, World!&#39;, Gosu.default_font_name, 30)<br> 9   end<br>10 <br>11   def draw<br>12     @message.draw(10, 10, 0)<br>13   end<br>14 end<br>15 <br>16 window = GameWindow.new<br>17 window.show</pre><p>Obviously, we require our gem here. Then we have our GameWindow class, which inherits from Gosu::Window, and we use super in our initialize to inherit the width, height, and fullscreen attributes from the parent class. With this, we default to a 320x240 window which we give a caption of Hello (the text that appears at the top of the window (next to the x — and minimize buttons). We then make our own instance variable @message that we create by using the Gosu::Image method .from_text <a href="https://www.rubydoc.info/github/gosu/gosu/master/Gosu/Image#from_text-class_method">[3]</a> with the text “Hello World!”</p><p>Alright, let’s run this and see what happens ^.^</p><p>Success! We have a little window to say hello to us now!</p><p>Step 4: Keep Calm and Make Games</p><p>It can be hard to see from this but Gosu is a really robust library that is capable of fun, yet simple, games. I’ll link some repos of example games made with Ruby and Gosu below!</p><p>Tank Island: <a href="https://github.com/spajus/tank_island">https://github.com/spajus/tank_island</a></p><p>Little Brat: <a href="https://github.com/blowmage/littlebrat">https://github.com/blowmage/littlebrat</a></p><p>Ruby Hop: <a href="https://github.com/blowmage/rubyhop">https://github.com/blowmage/rubyhop</a></p><p>Escape to RubyConf: <a href="https://github.com/blowmage/escape_to_rubyconf">https://github.com/blowmage/escape_to_rubyconf</a></p><p>Gosu Showcase(Forum for people’s Gosu games): <a href="https://www.libgosu.org/cgi-bin/mwf/board_show.pl?bid=2">https://www.libgosu.org/cgi-bin/mwf/board_show.pl?bid=2</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6a16beca3128" width="1" height="1" alt=""><hr><p><a href="https://blog.devgenius.io/game-development-in-ruby-using-gosu-6a16beca3128">Game Development in Ruby Using Gosu</a> was originally published in <a href="https://blog.devgenius.io/">Dev Genius</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>