I'm not talking about The Game, which you just lost.
I was playing a online game, where I have to go around the entire map to kill monsters. The name of the game is not important. (they might ban me for using automatic bots...)
I'm too busy to play the game thus I have to write a script to play it for me. Suppose I have a map, like the following one. 0 mean you can't move to it, 1 means you can move to it. There is a moving option, where one can move to one of the adjacent 8 spots.
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0 1 1 1 1 1 1 1 1 0 0 1 1 1 1 0 1 1 1 0 0 0 1 1 1 0 1 0 1 0 1 1 1 1 0 0 1 0 1 1 0 1 1 1 0 0 0 1 1 1 0 0 0 1 0 1 1 1 1 0 0 1 0 1 1 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 0 1 1 1 1 0 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 1 0 1 0 0 0 0 1 1 1 1 1 1 1 1 1 1 1 1 0 0 1 0 0 1 0 0 1 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 1 0 1 0 1 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 1 0 0 1 0 1 0 0 1 1 1 0 0 0 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 0 1 1 0 1 1 1 0 0 1 0 1 0 1 0 1 0 1 0 1 0 0 1 0 0 1 1 0 0 0 1 0 0 0 1 1 1 1 1 0 1 1 1 1 1 1 1 0 0 0 0 1 1 0 0 1 0 0 0 1 0 0 1 0 0 0 1 0 1 0 1 0 0 1 1 0 1 0 0 1 1 1 0 0 0 0 0 1 0 0 0 1 0 1 0 1 0 0 1 1 1 1 1 0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Given a starting point, find a path with minimal amount of movement that visit every spot at least once.
Humm, of course this problem can be converted to a TSP and bash though the NPC stuff.
Uhh, I'm going to use javascript to do this, so its going to be way too slow to implement a naive TSP.
Compare to normal TSP problem, there are some special features of the graph,
Some ideas:
Condense the chain of vertices with degree 2 into 1 vertex
Find subroutine deal with n*m rectangles
Let TSP take on the rest
There is more.
The player will know if there are enemies in the 8 spots around them.Those spots are no longer necessary to be visited, but setting it to 0 might disconnect the graph. A small modification is required to handle such cases.
It's too late to think, I will try this problem tomorrow.
Edit: No, it's not a TSP problem, this problem allow node be visited more than once.
I assume a good solution can be made simply transverse the graph.
There is a game called Numbrosia. The game is a 5*5 board with each block have a integer value. There are few operations, add 1 to every single block in a row or column. Shift every block in a row left or right. Shift every block in a column up or down. One want to minimize the amount of operation to get all blocks to 0.
We only consider Numbrosia with positive numbers. (if there are negative integers, just add the same amount of number on each row until all numbers are positive)
Now, create a generalized Numbrosia. Where it is n*n board instead of 5*5.
First question. Is all configuration solvable.
Answer. No. When the sum of all numbers is not divisible by n. It is not solvable.
If, the sum is divisible by n, is it solvable. Yeah. There is a simple yet inefficient algorithm to make sure you go solve it. Taking way more than the amount of optimal steps.
(a,b) = the position,
= value at that position.
First, let's suppose it's we have a positive integers in each block. Find the lowest positive number, reduce it with the same row until it's 0. Do the same thing to other numbers, except if there is 0 on the same row, move it away until all numbers on the same row are positive. Do it until there is only one row left. Just to make everything easier, suppose that row is
to
and
when i<=j. It's ok to assume since it's possible to alter the blocks into any arrangement if it's not in our desired formation. 
Now, there is a simple algorithm to solve the game in this condition.
1. Do addition on row 2 so all number on row 2 = 1.
2. Move 1s from row 2 to 0s in row 1. If there is not enough 1s left, after all 1s are moved to row 1, go to step 1.
3. subtract row 1 again. Now there are 0s in row 1. If there is only 0s in row 1, end.
4. go to step 2.
So clearly, it is possible to solve a n*n Numbrosia when the sum of the numbers is divisible by n.
I assume the minimal number of step to solve it is 2an, where a is the largest number in the game.
Cave story is a casual game.
It must have been played by millions by now.
Eye candies:
This post contains SPOILERS. the entire post has SPOILERS! Skip it if you want to try yourself. Or if you are like me who doesn't care about spoilers, read on.
I have played all three endings and feel my soul have been upgraded.
The story is extremely simple, but the provoke ideas requires lot of thinking.
The fate of irony isn't really hard to grasp. During the game, there are a few moment worth remembering. The death of Toroko and King. King who tried to defend his village ultimately failed. Quote had to kill Toroko even that who he tried to save. Irony of fate.
Are there anything important about memory should be learned from this work?
Memory is history in personal level. When someone else knows the history, they can exploit it.
Doctor convinced some Mimigas to work so they can fend of something in the future that could be the recurrence of the past, but they are actually leading themselves to their doom.
The main protagonist Quote is a robot who lost it's memory and got entangled to stop the Doctor, and never regained his memory back.
After Curly Brace recovered from her memory loss, Cthulthu said he liked her without the memory better. Strange. Does this means anything?
Why are Curly and Quote, two robots seems so human, they need air, they can eat and they also have emotions. Are their emotions created by having memories?
There are times where people scream when their hard disk fail and all their data are lost. They often say all those important memories are gone with it.
So humans have that many important memories they want to remember, but their brain is not capable to store that much. Is it true that some memories are made to forget?
Humans are just shells, like Curly and Quote. Memory is what really defines a person.
If one can change his own memory, would he? As some memory can make him the person he wants to be, but also means he ceased to exist to himself.
Why is this game called cave story when the island is actually floating in air?
Because Quote started in a cave, and end up in caves until he finally found out it is not a cave during middle of the game. That's my opinion...
The ending is quite a happy one.
The Game is a popular(really?) game played by anyone who is in this game. There are a lot variations but you can just follow the Wikipedia rules.
Since everyone is in this game, we should come up with a rigor definition of everyone.
Any organism that is currently alive and homo sapien.
Because the condition for losing is to think of the game, there have to be some definition of thinking.
What is thinking? how can we define if someone is thinking about something? I don't know. You are the one to judge.
Losing is think of the game, but should they be a gap between losing? What if I continuously thinking about the game for 10 hours, is that only one lose?
People come up with different gaps. Like 30 minute since last lose is the same time.
The loser have to announce he is lost. In any form, include spam.
Is there a way aware of the game but never lose?
Yes, in theory. But in practice no.
Some people have suggested that one can isolate himself in a place where no human can contact, so there is no way a outside influence can make him lose.
But a common man will ask himself why is he here, and then he will think of the game and lose, all the time.
While the primary goal is hard to achieve. Making other people lose are quite easy. All they have to know, is to aware that about the game.
Advertisement!
Use all the marketing skill you are aware of.
Facebook wall posts
Discussion groups
Forum signatures
Spam
Tatoos
Blog posts
School Newspaper hidden message
Super bowl ads
and of course, spam.
What's the point of this game?
Nothing...
But there might be some mathematical model hidden worth investigating... Anyone want to suggest one?
Problems
more philosophical + mathematical + deep questions I come up with when I have nothing else to do...
I'm enrolled in The Game without my knowledge, is that still enrollment?
Does I have a free will?
if I don't, why don't I?
If I think I'm not playing the game, am I still playing the game?
Is your mom losing The Game?
Why if someone else define something, I have to be restricted by their definition?
Is freedom subjective or objective?
Who will win this presidential election?
Is free will really free will if it's controlled by the outside?
Is life subjective or objective? If people want to win, why do they post stuff like this?
Does the original creator imagined this?
Is he still alive and using this as a way to test human psychology?
Is he LOLing?
Is he a communist? is he Mao? Is the Chinese trying to take over the world? Is Mao still alive but we just believe he is dead? Is Mao who we think he is? Is Mao actually a conspiracy created by the US government? Does China even exist?
What is the consequence of cheating?
Why don't people cheat?
What make people cheat?
Can I get into USAMO?
Does people shout "I lost the game" during tests? Is it allowed? If it's not allowed, is it against the freedom of religion?
Does inform people that one lose is a way of spam?
Is this the world largest spam network?
Will this game ever be forgotten? ...in bed?
What's the possibility that no one in the world ever remembers this game?
Can other organisms join this game?
Is lose really bad? Is win always the best goal?
If win is impossible, is lose really means anything? or should we redefine win?
Is Latex the best material for condoms?
Why should anyone lose?
Can't everyone just win?
Can dead people still have minds?
What happens if one change the word "lose" to "win"?
What sociality impact would it create?
Am I in the Matrix?
What if both game present at the same time?
What if one create -(The Game), where think of the game wins?
What if think of -(The Game) will also considered lose for The Game?
What if there is a constant amount of time required to think of The Game to lose once?
What if that is not a constant but a variable?
what is more important? winning the win able one or not lose the lose able one?
What if there is more states than just win and lose?
what if there is n games create win situation and m games create lose situation when n and m have what property create people tend to favor the winning instead of losing?
If each of those game have different weights, does individual game score matters to people or just the combined weighted average?
What's for dinner?
What if it become a point system?
Making other people lose you get point and if other loses, they lose point?
How should the points be added?
Adding constant points?
or should it add points with specific property?
Should it only use addition?
Can it use w/e other function out there?
Can the points be complex or even higher extension of numbers?
Can the point be vectors, matrix or even tensors?
Is Facebook behind all these? BTW Peter and Pelle if you are reading this... Get a Facebook!
Is it true that the professor who taught Math 254A course in MIT become immortal?
Can there be randomness in the game? for example throw a dice and if it land 6 then no point is subtracted?
What if each player have an armor points?
How can player gain armor points?
and a dice roll below the armor points can get armor save, where their armor get removed and they points get lowered down?
Should the player chose when to use the armor save?
Can this game prove logic?
When should a player use a armor save if he can make the choice?
Does math major get laid more often than theoretical physic majors in college? If so, why does math majors get laid more often than theoretical physic majors in college?
Can we establish some rule that can use all humans who play this game part of a huge calculator?
If so, how to distribute it and how to make these plays generate information, exchange information and in the end make the people who cares about these information get these information?
Is this calculator a Universal Turing Machine?
Can it in the end create a mind control system?
If people are mind controlled, when they think of the game, do they still lose?
If it's a mind control system, how to break out of it?
Can one inside the mind control system manipulate the system?
If one can, how to prevent them not to manipulate the system?
Can I use this system to rule the world?...in bed?
Did anyone read the "evilplan" word file in my flash drive?
Does The Game make sense at all?
Endless of questions there...this is such a provocative game of mind...
Someone, answer me at least a few of them.
I will do research too.
One of the best game I played in my life would be The Legend of Sword and Fairy[仙剑奇侠传, Xianjian Qixia Zhuan] or usually referred as it's program name in DOS, Pal. The other game would be LF2.
I played this game for 24 hours straight. I cried in the end... like I did when I first played this game when I was 7. The touching feeling is the same... the only difference, is I can't understand the deeper meaning behind the story back then.
The Setting:
The game is in both a Chinese fantasy world and a Wuxia world. Even it's not said in the original game, it kinda follows the following fictional world established by the sequels(which sucks and doesn't have a lot to do with the original).
The world consist of 6 different kind of beings.
The Shen(or gods), don't know where they come from... but Xian can become Shen. Shen can't reproduce. Shen seems to have power to make Xian or other inferior Shen into human.
The Xian, between Shen and Humans. Those are enlightened immortal humans have power beyond normal humans and still tries to reach the level of Shen.
The Normal Eukaryota: Yeah.. like humans, dogs, cats, flower, fungi and all other living things except ones in Archaea and Eubacteria.
The Yao(short for Yaoguai): Like Xian, but instead of humans, it is plant, or w/e other living even not-living things gained a lot power. In normal Chinese culture, anything living thing out of ordinary and not considered as good can be called Yao.
The Mo(or deamon): Just like Xian can become Shen, Yao can become Mo.
The Gui(Ghosts): You know what ghost means right? it means the same thing in all cultures. Usually ghost follows the path given by Buddhism.. they reincarnate as someone else. Before reincarnation, they have to drink a soup, which will erase all their memory.
The Plot:
You can read Wikipedia for the full plot. But Wikipedia's plot missed some info. So I'm going to show you the full plot of the start of the game and abridged version of the rest.
Small spoiler, introduction
Li Xiaoyao(In China, last name position first) was a kid who want to be a great hero and lived with his aunt, who owns a inn. Soon, his aunt got sick, and he want to save his aunt. The Miao leader who lives at his inn gave him a pill(which makes him forget stuff), and told him to go to an island to find a medicine that cure any disease. He go to the island and destroyed the island's special maze and find Zhao Linger. Who gave him the pill. Zhao's grandmanot genetically related come home and wants to kill Li because she fear Li reveals the island to the people they are hiding from. So Zhao's grandma transformed into her Nüwa form(basically...human upper body with snake lower body) and scares Li. She give Li 2 choices, either leave the island without 2 hands and the tongue(so he can never speak to write), or marry Zhao and live on the island forever. If he don't chose, she will eat him. Li is forced to marry Zhao.
The 2nd day after they get married, Li sneak out of the island so he can deliver the medicine to his aunt. After his aunt took the medicine, the pill from the Miao leader come to effect and destroyed Li's memory of past 24 hours. But he remembers to meet a drunk guy with mad skillz. Li sneaks out and meet him. The drunk guy teach him some techniques and left.
When Li tries to sneak back, he found his room got rented by the Miao people. He sneak back to his room from a secrete passage, and found Zhao, who become the hostage of the Miao leader. Li can't remember who Zhao was, but he and Zhao fought off two Miao soldiers who protect Zhao from been taking away.
Zhao and Li goes back to the island, and found everyone got killed and Zhao's grandma is dying. Her grandma told Li to take care of Zhao and died.
Zhao and Li goes back to the inn. Li and Zhao get confronted by the Miao leader. Who reveals the Hei Miao King(In the story, Miao have divided into Hei Miao and Bai Miao) want to see her daughter, Zhao. But Zhao doesn't believe in it and fought the Miao leader. After the Miao leader got defeated, he tries to capture Li's aunt when she walk into the inn, but got killed by her by one simple punch(she's bad ass strong, Miao leader have 800HP for god's sake)
Zhao want's to sleep with Li in the night, but was emotionally damaged when Li seems to forgot about the marriage. Li's aunt took Zhao away and tell Zhao to tell her everything.
The next day, Li's aunt give Li a package form his dead parents, and told him he should help Zhao find her mother. Li agreed.
So the story begins!! Big spoilers starts here
now.. for some small recap of what happened without all the details.
Li meet Lin Yueru, become her fiancee. Zhao disappeared. Li and Lin tries to find her... but she got captured by the Hei Miao people again.. then before Li and Lin meet with her, she got captured by people in Mt. Shu and put her inside the tower that lock Yaos inside.There will be a very touching story before Li and Lin go into the tower, but since it's not that important to the entire series development let's leave that out (some says it's more emotionally touching than the main plot, it's the most referenced segment of the game). Li remembered everything he forgotten and said they will live happily ever after or w/e. They fought the guardian, a Shen(2nd most strong boss in the game), destroyed the tower so they can get out, and release all the monsters during the process.[well... he messed up the world so there can be a sequel...smart] Lin's skull got crushed by a piece of the broken tower and died. Sad, she just said they are going to have a happy life. 
The leader of Mt. Shu bring them to a great healer. She told the leader there is no way Lin can be alive again... but she can make her, not dead...[yep. foreshadowing for the ending...]
Zhao needs special medicine because she was pregnant and having a non-human body. So Li tries to find some and meet Ah Nu, the daughter of the Bai Miao Clan leader. They found the medicine. Zhao give birth to a baby.
Zhao finally meet her mother, who was now a stone statue whom the Bai Miao people worships.
Zhao saves the Bai Miao and Hei Miao clan by ending a drought.
Zhao goes to meet with her father, The leader of the Hei Miao Clan, who was just a impostor of the final boss, the religious leader of the Hei Miao Clan. After the boss's defeat, he merges himself with the immortal ancient water demon, he said if it's not because of Zhao (the heir of Nüwa, seems like the only thing can destroy the water demon) is still alive, he can use the demon to control the world a long time ago. It's said nothing can stop him now because the water demon is immortal if there is water around it.
Zhao sacrificed herself to destroy the immortal demon.(wait... isn't the demon immortal???)
The game ends with the death of Zhao.
Only the staff once used by Zhao remains...
The ending was so ambiguous.. no one actually know what happened.
Li leaves Ah Nu to become the leader of Mt. Shu[according to the sequel], which he politely inclined the time when Lin and Zhao are both alive, because the requirements basically means he have no desire. I guess he's desire died with the 2 women he loved.
There is a image of Lin holding a baby in the ending. but isn't Lin died? the official explanation was... it's Lin's body... with Zhao's soul in it. Well I guess it's possible, Zhao is not fully human.
How can Zhao have babies? Because a mix between 2 different species(Zhao is a mix between human and Yao) can not produce offspring with reproductive abilities. But I guess biology over there is different.
There is a great argument about if Zhao is a Yao or something else.
Look at the English title. The fairy suppose to be Zhao, and fairies are considered as Yao. Zhao referred to herself as having the body of Yao, another support. But really... who cares...
Spoiler ends
The rest:
The entire game was written in QBasic.
The graphic was considered successful back in 1995. I don't think there are more than 256 colors, and one pixel are stretched to 4 pixels in the 640*400 resolution. Which means 320*200 screen is enough to retain all the data. Produce such a epic game in that resolution is truly a skill.
The background music? I still remember it now.
Why is the game so touching? I don't know... I don't know why I cried like all other Pal fan when the main characters meet their fate. Maybe, it's the feeling that there is nothing I can do.
Many RPG games have multiple endings, this one doesn't. It's the full impact of fate. Something is going to happen, and the player have no control over them. It's the same of reading a book.
No matter how the sequels, the TV dramas and the official not-that-great novel ruin the original. I will always be a fan of the original Pal.
I'm definitely going to break the copyright law and create a English version of that game. I'm putting hope on SDLPAL. They are a active group, the newest source code update was 3 days ago. I'm offering them a place for hosting on my hosting. Or if they want their own, I can manage for them and pay for their hosting if it's not too expensive(say... $30 per year is ok with me).
For the people who don't want to play the game, it's easy to just record important scenes + add some subtitle to a 90 minute movie. It surely won't take a huge amount of space [320*200 pixel, 256 colors, a lot repeating frames]. This adds to one of my plan after I finish my undergrad years.
BTW I love True Lemon, get your free sample! I actually liked it!
And I got 2 old(1962) textbook for $4.35. Boolean Algebra and its Applications by J.Eldon Whitesitt and Calculus With Analytic Geometry - A First Course by Murray H.Protter and Charles B.Morrey, JR. I need a proper textbook for my AP test.
Recent comments
2 days 4 hours ago
6 days 14 hours ago
1 week 20 hours ago
1 week 3 days ago
1 week 3 days ago
1 week 3 days ago
1 week 3 days ago
1 week 5 days ago
2 weeks 1 day ago
2 weeks 1 day ago