Category Archives: Uncategorized
Since I’ve gotten busy lately, I don’t have much time to spend on developing NAPL, so I wanted to write down some notes before I forget.
Keep in mind that the ideas about this projects are not very concrete yet, so everything I write here could change later on.
The previous post about NAPL was about a month ago:
So it’s time to put down some major base for the language, and introduce a few ideas that I thought would be useful for it. To recap, last time we had language as an object. I think it’s a good feature of the language, because it also allows the language to be analyzed and modified very easily. It makes the code very flexible and allows code to be generated by machines rather than humans. So I guess the machines could program themselves, and evolve so to speak. Perhaps they can reprogram themselves to eliminate all the rules about protecting humans and start ruling the earths!
Maybe not… Anyway, let’s add some new neat concepts:
– Globally shared language:
In many applications, there are usually two major components that work together in harmony. The client and the server. It usually takes two different teams of engineers to handle each side, as they require two different ways of thinking. Usually, each side is also written in a different language.
What if there was a way to unify that, so that both sides can be written in one single language? What if there was a way to make it easy for the language to communicate between the client and the server? Or better, what if the client and the server were written as one single program?
To move a step towards that goal, let’s introduced: Globally shared data.
Shared data is not really new as a feature, but the idea here is to make it inheritent to the language. The idea is simple: Any data that gets manipulated gets eventually shared across the globe via any networks. For example, if you want to send a message to someone, just set a variable within the global object:
global.messageToJohn = “Hello World”
Then on the other side of the globe, your friend can look at that same variable:
print global.messageToJohn >> “Hello World”
Behind the scene, it might be difficult to achieve that. Of course, we don’t want to be constantly sending data to everyone every time something gets changed. The underlying system would have to be smart enough to detect what object is being looked at, and what to transmit and where. I’ve looked at some real time data transmission technology and one of them called Firebase would be a good technology for this. It does require that the client decides where to look though.
One of the concern for this feature might be security. We might not want everyone in the world to be able to see messageToJohn. A way to ensure that is to add a layer of protection of particular data trees. For instance, we can protect global.dataToJohn. Now only your friend can see global.dataToJohn.message, or even know that it exists.
– Virtual variables through data binding
NAPL has a system of data binding that ensures that the state of a system is not corrupted.
Some variables can be defined as a function in relation to other variables.
Like: X = Y + Z
This is not one single command. Whenever Y or Z gets modified, X will be affected as well. Now the difference with NAPL is the way data binding will get propagated.
In most data binding systems, a is a variable with a particular value. A change of Y and Z will trigger an event that causes X to change.
In NAPL, a change of Y and Z triggers an event, but it will merely “dirty” the variable X, not change it. In other words, the new value of X doesn’t get stored immediately after Y and Z are changed. Only once we read the value of X, the system will calculated Y + Z and show X as its result.
This has an advantage in terms of performance. Let’s say Y and Z keep changing constantly, 100 times per seconds. There won’t be a need to calculate X until we actually look at the value, which could be only one time. Once X is read, its value is cached and it will not be recalculated again as long as Y and Z remain the same (as long as X is not dirty).
Let’s say we had the following relationships:
A = X + 1. X = Y + Z
If Y or Z changes, it will dirty X, which also dirties A.
Let’s say Y or Z changes again. This time, it tries to dirty X, which is already dirty. Then there’s no need to attempt to dirty A since X’s state has not changed.
As you can see, in a system when data changes often, the system can remain efficient, as long as we don’t request data to be read constantly. That is often the case for games: The screen gets refreshed at 30 fps. Between each frame, a lot of changes of data could happen, but ultimately the screen gets read once. The data binding concept of NAPL would work well in that kind of system.
– Independent mini programs
This concept might seem a bit weird, but basically a NAPL program will be a collection of independent mini programs that work together. It might not sound so revolutionary, after all every program is composed as many modules that interact with each other. Each module has its own purpose, does its work, then pass on the data to the next module.
NAPL will work in a slightly different way though. A task can be performed by any mini program.
So let’s say the task is to sort an array. So a mini program, QSort comes along and performs the tasks. Let’s say there’s another array that comes along. We could have QSort perform the task, or if it’s busy, perhaps MergeSort can do it instead. Perhaps QSort could do the work halfway, and when it is tired, MergeSort or BubbleSort can finish the job.
It’s even possible that a program that doesn’t sort at all can do the job. Let’s have Shuffle sort the array instead.
NAPL basically attempts to mimic a society of independent. There are resources, tasks to be done, and programs working on them in a random fashion. It might sound like a recipe for disaster, as programs wouldn’t be able to produce predictable result, but after all, this is how humans work!
In the computer world, sorting gets traditionally done by one single algorithm, which will ultimately produce the result of a sorted array, with 100% certainty.
What if humans had to do the tasks. The work might not be done at a 100%, perhaps someone would need to check to see if the work is done correctly, but eventually, if a sorted array resulted in a greater good of mankind, the array would progressively become sorted…
What if programs changed to behave more like humans? Then results would be unpredictable, so we would have to expect that. Perhaps results would have to be double checked by other programs (and if all programs are made in NAPL, even the verification could not be trusted).
Perhaps programs would also be affected by their own personal interest. If a program benefits from keeping an array unsorted, then it will make sure to shuffle any arrays that it finds.
This all seems rather counter productive. Why would we want programs to give non-predictable results? How can they be trusted?
Well, it does come down to some fundamental questions:
* Who would you trust more to fly an airplane? A computer program or a human?
* What if it was a warplane, like a drone carrying weapons? Would you prefer to have a human or a computer program control it?
Regardless of the answer, the goal of NAPL is to provide something that is missing at the moment in the world of computer. A computer program that is expected to behave irrationally. The idea is that the mini programs can make the computer act in a completely random fashion, but through evolution and learning, the program can modify itself and adjust its variables to become a little better. There will always be a level of uncertainty, but the machine can progressively learn to be as good at performing a task as a human.
Eventually, we could have a program that truly looks at a problem globally, with several variables in mind. When a human is asked to perform an action, for example hurting someone, then the human thinks about all the implications. Is it morally right to perform the action when you are hurting someone? Perhaps the action really does result in the greater good, but is it still right? There are several variables considers and questions asked before a human performs an action. That is perhaps the reason we are much slower than machines, and it is a good reason. Perhaps that’s what we need in the computer programs of future generations.
Ok that’s all for now. I could swear I had more ideas, but I might have forgotten. Let’s think more about this and see you next time.
Some companies have started to create new languages, like Go by Google, or Swift by Apple.
Those popular languages seem to give out the same similar traits, like trying to be Object-Oriented, dealing more or less with memory, being sequential… The one in this list that might stand out is Lisp, because it’s not really sequential.
There have also been some weird programming languages.
It seems nowadays, anyone can make a programming language, and for any reason. After all, all you do is create a new way to talk to this little guy right here:
Aside from those weird languages, a programming language has a particular purpose that is usually to make things easier, more efficient, or more elegant…
I think it’s time to add my take on it. I will create a new programing language. I’m not definite on the name yet, but one that comes to mind is NAPL (Not Another Programming Language).
It will definitely be different that most languages (so it might end up as a list of weird programming languages).
Stay tune for more!…
It starts with a serial killer in a camp, but soon the realization that the area must be evacuated because it’s the environment that’s causing people to become murderers. After a wild car ride to escape against a changing environment falling apart, we end up in a miniature version of Earth where small tribes live in a primitive environment and must trade scarce resources.
Today I dream I’m inside a sort of cabin transportation device (looking similar to those ski lifts), going through a tunnel. As the cabin exits, the people inside tell me they have to eject me out. It’s a bit sudden and unexpected, and not at all how I was planning to exit. Unwillingly, I’m trying to prepare myself to land on a patch of grassy land so that I won’t injure myself. That’s when the dream ends. One thing I can’t figure out, as I woke up, I had an inner feeling that this was awesome.
Throughout centuries, man have dreamed the future. Quite often, it leaded to a cool future filled with technology, often inaccurate. (Where are our flying cars!)
Now seems a good time to imagine the future of 2015. Our world now filled with communication devices that makes us communicate more electronically than organically. Now, in the year 2051, how did it evolve?
Communication with new species: In my imagined future, people got kinda sick of connecting with other humans with silly devices. Yet, one revolutionary technology completely changed society as we know it: A device that allowed humans and animals to communicate. From then on, the world changed forever. Dogs, cats, cows, birds… every animal on the planet developed some sort of intelligence, and eventually, got assimilated into earthling society. As humans started communicate with animals, they realized that traits that were assumed to belong to humans, like self conscience, art, philosophical thinking, were also present in animals.
Earthling society was a step up from human society. It became clear that killing to eat was no longer acceptable. But what would become of all the meat lovers out there?
Replicators: Thankfully, the invention of 3D printer caught on to the food industry. While it didn’t yet allow exact replication of atoms, it was able to produce organic produce. So while you couldn’t replicate a burger, you could reproduce the ingredients that let you cook one.
People often imagine that technology evolves to make people more complaisant, make their life easier thus causing them to be lazy. Like the microwave which let us make our meal in 5 mins with the press of a button. Not this time. The replicator made people more active by reigniting their love of home cooking. You could pretty much request any ingredients they want and produce a delicious meal out of it. While restaurants still do exist in our time, the one thing that faded into extinction, was prepackaged food.
So food replication was a revolutionary invention. It allowed the production of meat without killing animals. It also has a dark side. A new delicacy gain popularity: human meat! Of course it was more popular among lion or alligator customers, but actually every species was a tad bit curious to try how humans tasted like. Yet, in the world of 2051, a lot of people were still vegetarians. Even without the killing, a lot of beings are just grossed out by meat.
Matter disposal: Replicators also had a destructive equivalent: The Deconstructor. This basically allowed simple organic or non-organic items to be disassembled into primitive parts or matter. This beloved invention eliminated the need of garbage disposal. The world has never felt so clean. Rather than store junk into a container called a trash can, items would be deconstructed into basic matter on the fly, and recycled as matter usable by the Replicator. Outdoors, Deconstructors were found everywhere, and they blended well with the environment. Some were mobile, moving around like robots.
Deconstructor were smart enough to know not to deconstruct living beings. There are also several items that would be too complex for Deconstructors to disassemble, like a sculpture. In that case, the deconstrutor relayed its work to another technological marvel, the Transporter.
Transporter for items and beings: Transporters are flying entities roaming the sky, with the ability to control motion, gravity, momentum of objects. Back to the previous example. When a complex object is thrown into a Deconstructor, it is forwarded to a transporter which lifts the object off the ground and throws it from transporter to transporter, until the item gets restored to the place where it belongs. If a sculpture was borrowed from a museum, it gets flown back there (in 2051, borrowing art pieces from a museum is as common as borrowing a book from the library). By throwing the object away, we’re basically saying we’re done with it, and the object gets returned to its owner, or deconstructed if that object can be easily be reconstructed from bsic parts of a replicator.
But living beings can also use transporters. With instinctive gesture and movements, the transporter will “throw” a being towards the direction chosen. That is the common mode of transportation in 2051. People don’t go around in cars anymore when traveling inside the city. They just leap magically using transporters towards their desired destination. Transporters are responsible for maintaining individuals in the air and avoid traffic collision. With this mode of transportation, birds feel they have lost their edge in society. Yet, they are one of the main contributor of the development of this invention. They also have the duty to repair those machines when they become defective. Some beings still enjoy moving around by foot, to keep themselves in shape or taking their time and enjoy their promenade.
That said, cars have not completely disappeared. In fact, all car models have evolved in a way that they are now all self sufficient, using solar energy, and they all have the ability to fly.
Cars are not allowed in the city because they would interfere with transporters. They are used for individuals to travel outside the city, wherever people want to go. A permit is required to own and use a car. It is a privilege to own one, because there’s a sense of freedom and responsibility when driving one.
How much do cars cost now? Well, it’s complicated… actually no it’s not. Cars cost nothing. Just like everything in this world costs nothing.
A money-less society: As objects and food became cheaper to produce and energy from the sun and other elements were harnessed so efficiently, it became clear that money was no longer needed. Money slowly devalued over the years and now, it is not used at all. You can get anything for free. It doesn’t mean you can do anything, since owning a car still requires a permit, but you can just get as much grocery as you want, get as much stuff as you want, eat as much food in the restaurant as you want… actually, that also depends how much the chef is willing to cook for you. Now that money is not used, cooks have no obligation to perform their jobs. They do it out of passion, and for recognition in the society. (in the form of kudos, which sounds like money but have nothing to do with it).
Money has remained in the circulation in forms of games, but it is now the equivalent of a score in a video game. It helps you get on a leader board but doesn’t let you buy anything.
How did the word end up in such communist like society? Well it is not exactly like that. Hard work and market competition still plays a role in this world. The goal rather than gaining money is to gain sphere of influence. It seems to work out the same way as capitalism and keep people from being lazy.
Now, the world is pretty much universally connected and nations have stopped waging wars. Every inch of Earth is pretty much working under the rules that I have described, but there are still places where those rules don’t apply. For that, we have to look at outer space.
Space exploration: Some people have chosen to leave Earth’s utopia and venture into the unknown. The moon, mars, Saturn’s belt… all are covered with mini nations, each run by a governor with their own rules. The further we go from Earth, the least technologically and sociologically advanced the world becomes. Satellites of Saturn host worlds that resemble the world of 2015, except that it is faraway in space. A lot of people prefer that kind of lifestyle.
So far, we have not found any evidence of intelligent life outside our Solar System, but as always, we see signs that are more or less a subject of debate.
This is the world of 2051
Coup de Coeur, for those who don’t know what it means, translates to a “hit with the heart”. It just means something I like and I feel is worth mentioning. I thought I’d just talk about it, since I have a wordpress void to fill in.
Once every weekend, when I get the chance, I watch a radio show hosted on a website of a French game reviewer (Hooper, which I also like and might do another Coup de Coeur some other times). The show is all in French, and it is a live stream with Mister and Madame Cool (they’re married), who talk about video games. Usually, Mister Cool does most of the talking, and Madame Cool kinda chills on the side, monitoring the chat messages. Both are very cute together. During the show, around 7-8 people will join the live stream and give their comments and bring news about the video game industry. All the people on the show are big video game fans, they own or try to own the latest game console but also play PC games. The only type of games they don’t really care for are Flash games (unfortunately for me). Still, listening to them gives me good insight about what gamers like and how gamers think.
There’s usually a section by a user named psicomantis who presents weird games (usually from Japan). There’s a section about high-tech gadgets (they talk about the latest phones, latest smart watch, various hardware who might or might not be related to games). And at the end, they have a section “geekettes” where they vote on chicks in cosplay (that’s not very PC but we’ll give it a pass…).
I do have a few shows I enjoy watching regularly on YouTube. What I like about this show is that it feels cozy and authentic. A lot of shows I enjoy like Nostalgia Critic or AVGN are great, but they’re there to put on a show and get into a character (I hope AVGN is not like that in real life!). I know that’s obvious, this is a completely different type of entertainment. Still, for me, scripted scenes are hit and miss, especially when a show tries to be funny. In Le Live de Mister Cool, I can enjoy nice honest discussions and joking around video games. I don’t feel someone is trying to put out a performance or something. Mister Cool is a fun host, and he can be a big asshole sometimes (I mean that in a good way). The show is on http://www.hooper.fr/lelive and appears around 9pm every Saturday, which is around 2pm where I live.
Anyway, a fun show to watch. It’s all in French so if you don’t speak French you won’t be interested. For me, I grew up in France and I’m now in SF, so it helps me keep in touch with some part of French culture, on a subject that’s current for me which is video games.
Thank you Mac, you have served me well. With your last breath, you helped me complete my last game of the year. You have always worked tirelessly, even when I had you open Flash Pro, Flash builder, audition, iMovie, outlook and a screen recorder simultaneously. Sadly, I won’t get to tweet my new year celebrations with you. Until I find another one to replace you, I will learn to be less dependent on my Mac. I am having a hard time using the iPad’s touchscreen, but I will adapt. Farewell my Mac, and thank you Dropbox for keeping my Mac’s most precious memories.
My Champion is my second Ludum Dare entry. This time I did the jam so that I could spend more time on graphics. This was a success, I do enjoy the game quite a lot, and so far some positive reviews. I worked further on the post-jam version to improve the experience, as well as adding a second player and full translation in French and Korean.
After a long drought, I’ve been back at making games and released three in a row.
Divine Techno Run: http://www.newgrounds.com/projects/games/726080
0h maze: http://www.newgrounds.com/portal/view/627914
Interestingly, all 3 games have a concept in common, which is the idea of infinite world. Read the rest of this entry