Welcome to the website of an amateur research and development center! Started off with game development, Sadale had developed pretty much everything, including games, music and research works. In the future, more products will be developed (well, as if anyone would care about that).
All products mentioned in this website are my own work, unless stated otherwise.
Our core value: Development in Stability
Online Middle-Square Method Generator - A web tool that I couldn't find elsewhere. [Link to the Tool]
animeVPS - A low-end, donation-based VPS service that I'm hosting. [Website]
歡迎嚟到薩地魯嘅網站. 曾經係業餘遊戲開發者, 今日薩地魯利用佢嘅業餘時間, 乜都整餐懵. 包括遊戲, 音樂, 研究項目等等.
絕大部分嘅blogpost只有英文版. 當然, 都有D有廣東話版嘅.
核心文化: 穩定為先, 開發為本
Bonvenon al la retejo de Sadejlo. Sadejlo estis amatora kreinto de ludoj. Sadejlo nun kreas ludojn, muzikojn kaj esploradojn. Ĉi tiu retejo estas plejparte Angla, kun iomete Esperantaj skribaĵoj.
Slogano: Stabile Kreadu
Hey guys! It's that time of the year again! Our awesome Rock Paper Scissors Tournament will soon be commencing, and its website's ready! :-)
This is supposed to be an annual event. However, it didn't happen last year because the hoster failed to set up the site. Therefore, we're going to host this event on our own this year.
We'll be issuing certificate of participation of all of our participants! If you're looking for a degree or a job, certificates are proven to be helpful on building your portfolio. That's why we're issuing them! Put that in your resume and we promise that'd secure your job offer or degree offer!
This year we've also made the captcha easier than it used to be! We believe that it'll invite some bots to join our event. That'd make our tournament even more competitive than it was! :)
The front-end is almost the same as the old one. Semantic-UI were used. But we've changed the back-end from Django to Flask. Flask takes much less RAM compared with Django. And it takes much less efforts to develop stuffs using Flask, especially for trivial projects like this one. I guess Django is better suit for larger scale websites.
I guess I'll be opensouring this thing. But I'm too lazy to do so right now. Maybe later. :P
I'm thinking about making an AVR (non-Arduino) portable game console. I'm evaluating the type of display to be used (including multiple 8x8 LED matrix, graphical LCD, TFT/OLED screen, alphanumeric LCD and combination of them). Then I came up with a weird idea. What if I use a alphanumeric LCD as a graphical LCD? That'd cut me quite a bit of the cost compared with using graphical LCD of the same physical dimension.
I'm a bit bored today. I feel like tinkering around with Arduino and 1602 LCD that has been around in my home. Here's what I've got as a result of hours of boredom. An Arduino-based 1602 Snake Game:
Check out the source code in this github repository!
The hardware is roughly based on this official Arduino LCD Hello World tutorial, with an addition of two push buttons.
The left push button is connected to D8, while the right push button is connected to D9. Both push buttons are pulled-down. For other connections, please refer to the schematics in the tutorial.
HD44780-compatible LCD driver supports up to 8 custom characters. By carefully defining those 8 characters, it's possible to subdivide each character into multiple "pixels". That can effectively turn the alphanumeric display into a graphical LCD display.
My design subdivides each character two rows. Each row on the character can be either empty, snake, or apple as shown below:
There're two "pixels" in each character. Each pixel can have three possible values. Therefore, the total combination is 3^2 = 9. Since one of these combination is visually empty, a space character were used to represent that. At the end only 8 custom characters are needed. So the 8 available characters in CGRAM of HD44780 are just enough for our purpose.
To reduce RAM usage, each pixel is represented by 2 bits. So a byte can store 4 pixels. Everything is cramped into a
uint8_t graphicRam[GRAPHIC_WIDTH*2/8][GRAPHIC_HEIGHT]. At width of 16 and height of 4, only 16 bytes of RAM are taken for the graphic! Had I used a uint8_t for each pixel, 64 bytes of RAM would be required.
After the completion of this project, I've found other designs like spliting each character into three rows, or try making use of all pixels by generating the CGRAM on-the-fly. I'll consider using these techniques for my future projects.
To make the position looks random, we need to somehow seed the random number generator. For computer programs, we usually seed it with the current time of the machine. However, this couldn't be done on Arduino because it doesn't have a real time clock.
My solution is to make a menu screen of the game. When the user start the game, the time of the moment that the user pressed the button is used to seed the random number generator. The micros() method of Arduino Time library were used. This has the equivalent effect of using system time.
I was having fun playing with this game. I thought that it was reasonably bug-free because I had played it for a while. I've also asked one of my family members to try it out. I swear. We haven't spotted any bug.
Until I tried to record a video of the game play, something funny happened. I realized that I haven't implemented self-collision detection of the snake. I was like "Wow. How come no one had notice that earlier?". Hah. What a terrible failure!
Upon the discovery of the bug, it was fixed in no time.
Seems that using alphanumeric LCD as graphical LCD is promising. I'll consider going for this solution for the portable game console project. Of course, I won't be using Arduino for that. Arduino is good for prototyping. But it isn't as efficient as lower-level C/C++ programming.
I've played this game for many times. While it's technically possible to win, I haven't managed to do so. And I haven't tested the code of winning the game. I doubt that anyone could beat it anyway. I guess I'd just leave the code there as it is. :P
Alright. That's enough fun for today. Gotta sleep.
This year, I have done another Global Game Jam. I did it in Hong Kong again. Mainly because I was being too lazy to try out other jam site for this year. :P This year I had done something different. I did music instead of programming.
I had spent quite a while for practicing using Musical Palette - Melody Composing Tool, LMMS, LabChrip, sfxr and Audacity. I've figured out an efficient method to produce music. That is to come up with melody and chord harmonization by using Musical Palette, then import them into LMMS to further process it. I managed to produce a few pieces of good quality 1 minute music, each of them was produced within 24 hours.
For the LabChrip and sfxr, it's nothing more than about using the randomizer and manual fine adjustment of the parameters. And Audacity is even easier. It's just useful for noise cancellation and applying effects.
Just like the previous years, I came to the site without a team. As I planned to do music this year, it isn't possible for me to do it alone. So I sought for a team right after I entered the jam site. I tried requesting joining a random team by asking them and got politely rejected. Then another team with three existing members waved at me and asked if I was alone. I answered yes, told them that I made music and got accepted into the team. Then I had a dinner provided by the organizers. Here's a pic with more than 300 jammers begging for free food:
In the midway of our game design discussion, two of the team members had left their seat temporarily. Since I had no idea about the roles of other team members, I asked the remaining member about their role. He told me that he did art, one of the other team member did programming, and when he tried to explain the role of the last team member, his was like "uhm... uh... he's... uh... good at coming up with, uh... uh... ideas and presenting, uh... the ideas". :P Then I ended my question with "Ah. He does marketing. That's good." What I thought was that "He gotta be an idea guy!" :P
When all of the members were back to the seat, we ended up with a consensus on the game design timely.
Then we started connecting to the internet with WiFi. It was very unstable. Then I tried using mobile data by USB tethering with my smartphone. Surprise! Even mobile data is stabler than the WiFi connection provided by the organizers. Since I had a data cap, I had to use my data wisely. So no youtube for me.
I had started to draft a piece of music in the first day. Musical Palette were used for drafting the music.
In the second morning, I managed to caught the shuttle bus provided by organizers and arrived at the jam site early. I had breakfast. There's some open area in my jam site. It's rather interesting to see those people standing and eating outside. Some of the jammers had a bit distance in between possibly because they don't know each others.
After the breakfast, we got back on working. I gave the on-site WiFi another shot with no luck. And I used my mobile data again.
Then I was sitting along with the marketing guy. I sporadically took a peek on what he's doing. That was funny. Most of the time he had his Mac laptop playing youtube video, surfing facebook or chatting with instant messengers. At the same time he was holding a smartphone playing games on it. That was impressive. He was taking multitasking to the next level. To be fair, offering critical opinion requires playing others games. Anyway, he did spend a bit of time to look for info about how to make an awesome trailer for games, and studied about the good indie games.
Then the real fun begin. I continued making the music and completed composing with Musical Palette. Then I started working with the same piece of music with LMMS. However, it didn't went as smooth as I thought. In the midway of making the music, I asked my teammates to review it. Then the marketing guy complained that. He demanded a piece of music with abstract wordings that I couldn't understand. :P As you know, musical stuffs is difficult to be described by words.
After a while, he provided me an example of music that he's interested in. That was the BGM of Plants versus Zombies. It was a piece of music with drums without melody.
Then I toss away the old piece of music, made a new one and came up with this in Musical Palette:
I had never made this sort of music before. Using the same chord over and over again for 16 segments (or phrase in that program). Chord variation techniques were used. It isn't the sort of music that I like. The music sounds extremely stressful like playing airport traffic control games. But it does fit into the theme of the game. Then I mastered the piece using LMMS:
That's crazy. The same chord is played for a long time as shown above. I had added some sidechaining to it. Then I showed my teammates this piece of music. And they're ok with that. It seems to me that it isn't perfect to the marketing guy. But apparently he compromised and told me that this music is ok. That's possibly because of worry of time constraint.
Then I started working on the sound effects. That was rather easy to me. Depending on the sort of sfx, I used LabChrip, sfxr or remixing recorded voice with Audacity.
Working with LabChrip and sfxr was easy. Just click on those randomization button until I get a sound that's close to the one that I want. Then I adapt it a little bit and that's it. Using Audacity is still easy, but it has a bit different workflow. For the sound effects that's simple, I just performed noise cancellation and reverbed it. For sound effects that has like having many people saying the same something, like wow, or laughing sound, what I did was to record the sound for multiple times myself. Then performed noise cancellation, overlapped those recorded sounds, and reverbed it a bit and here we have it.
Speaking of noise cancellation, I'm rather surprised at the noise cancellation capability of Audacity. Behold a screenshot showing the power of the noise canceling effect:
We were in a noisy room with a lot of discussion from parallel teams sitting right next to us as shown below:
The result was brilliant. I seriously thought that I had to get out of the room for recording the voice. I'm not sure if it's solely Audacity, or it's that I was using a headset (Kingston HyperX Cloud Core) that allows me to put the microphone closely to my mouth for clear recording. But still, considered the environment noise, the result of the noise cancellation was very impressive.
At the end of the second day, I went back to home. All of the teammates claimed to stay overnight.
In the third day, I woke up a little bit late. So I couldn't get on the shuttle bus. I arrived the jam site by myself. After arriving at the site, I've found that our programmer had got back to home last night. And he would be doing remote working for our team for the day.
The third day was relaxing. There wasn't much for me to do. After goofing off for a while, our team had started producing the promotion video for our game. The rule of our jam site is to make a one minute trailer for the game. So I had make a piece of music dedicated for the trailer. The art guy did the video and synchronized the text with the music. The resultant video was quite good. The programmer had uploaded the game and our team members were happy about the game and the trailer. I haven't had time to try out the game that our team made, tho. That's because I was on linux, which is unsupported by the game.
After that, the marketing guy had come up with a story written in the description of the game. Then I extended the story with better wordings. Right after the game submission deadline, the artist and the marketing guy left because they were exhausted of staying overnight. At the end the marketing guy didn't do much other than giving critical opinion and discussing the game design. It seems to me that that guy is more like a quality control guy.
I had got a bit of time to chat with a few interesting jammers on the site. Before I had the time on socializing with them. presentation session had started. It mainly comprised of playing those 1 minute trailers. When it was my turn, I was rather surprised that the volume of our trailer were so low. I don't know if it's the audio of the vid itself, or the staff had set the volume level to too low. After that, the sponsors gave awards to some well-performing teams. And that's the end of the Global Game Jam of 2018 to me.
We took shuttle bus to a major metro station and got back to home.
After getting back to home, I tried playing the game that our team made. I was rather disappointed with the game. It was severely bugged and it isn't even remotely playable. Despite that the trailer looks good, the game itself sucks. Then I tried out other games produced in our jam site. They had similar problem. Super buggy. Not playable. Good or mediocre trailer, but no fun to play with at all. Wow. Seriously?
I guess now I've finally figured out the truth of Global Game Jam in Hong Kong. Almost all games here sucks with funny or semi-interesting trailer. Many jammers are just interested in getting an award. That's something that I truly hate because it isn't what a game jam about. If you like 48 hours game development competition, you could have just joined Ludum Dare!
I don't know. If I have enough spare time, I should seriously consider joining Global Game Jam elsewhere next year. The Macau one seems to be feasible because the guys there speak Cantonese, so there wouldn't be any language barrier to me. And the bridge connecting Hong Kong and Macau should be completed by next year. That'd make it easy for me to travel to there. :)
Despite that this jam isn't perfect, it's good enough. I'm happy about it. :)
Now I've a few pieces of music laying around. Some of them were produced for practicing making music before the jam. One of them is incomplete and was produced during the jam. Perhaps I can write a few songs with those music in the future.
And I also have some sound effects produced. Maybe I can create an asset pack with them.
Start your new year with the song that I've just released! Announcing Axial Inclination, the first English song that I've ever produced! This song is released under CC BY-NC 4.0 license. The source files of the music is available at the end of this blogpost.
Just like the last song, I made this alone. The music were made with LMMS. The workflow of making this song is a bit different from the last one. This time I use diffient harmonization over different part of the song so that it sounds less dull. I'd also carefully mixed the instrument tracks to add some dynamics to that. Hopefully it makes the song sounds better than the previous one. :)
Here's a screenshot during the production of the song:
In addition to that, I've modified espeak-ng, a text-to-speech engine, for generating the vocal, which is later mixed into the song using LMMS. It is reported that the lyrics sung by this vocal is difficult to be understood. Nevertheless, it's still awesome to have an FOSS vocal synth.
I've been busy lately. I'll release my changes of espeak-ng when I got time. This espeak-ng vocal thingie deserves a separate blogpost which will be available later this year. :)
CC BY-NC 4.0 license grants you permission to redistribute and modify this music for non-commercial purpose, provided that you give credit to "sadale.net". If you do not wish to attribute to sadale.net, or you'd like to use it for commercial purpose, please contact me with the email button on this website. Let me know what you'll be using it for. It's highly likely that I'll grant you the permission for using this music.
呢首係我第一首公開發放嘅歌, 歌名係"呢首歌嘅歌詞好奇怪". 首歌係關於呢首歌同埋佢嘅歌詞有幾咁唔掂嘅.
Behold my first song ever released publicly: "The Lyrics of This Song are Weird". This song is about the suckiness of the song and its lyrics.
首歌係我自己一個人整嘅(包括把聲同段片). 整左超過一個月. 如果你鐘意嘅話, 麻煩幫段片俾個like, subscribe個Youtube channel同埋share下俾你D friend. 如果呢首歌嘅反應良好, 我響未來將會整多D類似嘅歌. 多謝支持! :)
I made the song (including the vocal and the video) on my own. It took me more than a month to produce it. If you enjoyed the song, please give the video a like, subscribe to my Youtube channel and share it with others. If the reception of this song is good, I'll spend more time to compose similar songs in the future. Thank you very much! :)
我原本係為左整game而學整音樂嘅. 直至到幾年前, 我大概每一年就整一首廣東話歌. 呢首係我整嘅第三首歌. 之前果兩首太差, 所以我冇放到出來. 呢首我覺得唔算好好, 但係都算係咁啦. 所以我就決定放出來喇.
I learned music composition for game development. Since a few years ago, I compose Cantonese songs approximately once a year. This song is the third song that I've made. I didn't release the previous two songs because the quality were too bad. This one isn't good. It isn't that bad either. That's why I decided to release it.
呢個project總共用左8個軟件. 包括LMMS, Audacity, ProjectM, SimpleScreenRecorder, Inkscape, Spriter Pro, Aegisub同FFmpeg. 除左Spriter Pro之外, 其他都係免費嘅開源的軟件.
In total, 8 software applications were used for this project. They are LMMS, Audacity, ProjectM, SimpleScreenRecorder, Inkscape, Spriter Pro, Aegisub and FFmpeg. Except Spriter Pro, all of them are FOSS software.
This music was composed with LMMS. It's a music composition software designed for making music from scratch. I had briefly contributed to its development a few years ago. The voice was recorded and processed using Audacity. Some audio engineering was performed for the vocal track.
The procedure of composing this song is shown below:
我無正式學過作曲. 如果我用錯D專有名詞嘅話, 麻煩同我講聲. 我會更正. 另外, 以上步驟唔係唯一嘅作曲嘅方法. 以前我都用過其他方法作曲. 呢D步驟只係想解釋返我點整呢首出來嘅姐.
I haven't formally learned music composition. If I have used the wordings above incorrectly, do tell me. I will fix them. Please notice that it is not the universal solution of music production. I have tried out other approaches in my other songs. The steps above is just what I did for making this specific song.
Here's a screenshot of the song being edited in LMMS:
作廣東話歌同其他語言嘅歌有一個好大嘅分別. 就係要啱音. 我地有成6個音, 要對返個melody其實都有D難度. 仲要整到個歌詞嘅意思都要啱, 難上加難. 所以我作作下就卡死左喇!
Since Cantonese is a tonal language, I have to match the pitch of the melody notes with the tone of the Cantonese characters. Therefore, it's very tough to compose a Cantonese song as it's difficult to find the right word that has both the correct tone and the correct meaning. I was stuck in the midway while I was writing the lyrics.
Therefore, I had developed a tool to do this for me. The tool was written in Python. By using three Chinese word databases that I found on the internet, combined with the tone of the word suggested by Chinese Character Database: With Word-formations (which I had further modified manually because some of the tones were changed in the modern Cantonese we're using today), a list of words with matching tones is generated:
由上面嘅cap圖可以見到, 呢個工具可以列出個database嘅啱音嘅字(但係有小量錯誤). 例如我打240, 就可以搵到同"240"同音嘅字. 包括"亂晒籠, 垃圾蟲, 定晒形, 未夠喉, 滑鐵廬, 落晒形, 鼻涕蟲".
As shown on the screenshot above, the tool lists out all matching words that it found (with some minor errors). For example, if I type "240" (二四零), the first character of the word has to match the tone of 二, the second character must match 四, and the third character must match 零. The filtered result of the words is displayed, which includes "亂晒籠, 垃圾蟲, 定晒形, 未夠喉, 滑鐵廬, 落晒形, 鼻涕蟲" in the Chinese word database of Cantonese.
個工具仲可以俾你揀database. 目前個工具有廣東話, 大陸普通話, 同埋台灣國語嘅詞語嘅database. 雖然唔係所有歌詞都係用呢個工具作嘅, 但係呢個工具用來做brainstorming同埋搵D啱音嘅四字成語真係無得輸. 我以後應該都會繼續用呢個工具來填詞.
Database selection is also supported. The current version of this tool supports Cantonese, Chinese and Taiwan-style Chinese. This tool helped a lot while I was writing the lyrics for this song. Although I did not exclusively use this tool for writing all of the lyrics, it was very useful for brainstorming and finding Four-characters Chinese Idioms that match the tone that I want. I will probably continue to use this tool for my future songs.
不過好可惜, 我唔清楚部分database嘅使用條款. 所以我係唔可以放呢個工具出來嘅. 同大家講返聲唔好意思先.
Unfortunately, due to the unknown license of some Chinese words databases, I could not release this tool publicly. I'm sorry about that.
填完詞就用Audacity錄音同改音. 下面幅圖係我改音嘅過程. 只要複製highlight左果part就可以延長隻字個音長. Delete左果part就可以縮短隻字個音長. 呢個步驟不停重複, 直至做到把聲同首歌同步為止.
After the voice was recorded according to the lyrics written, Audacity were used for audio engineering. The image below shows how did I change the length of the Cantonese character that I had sung. By duplicating the highlighted part, the duration of that character is extended. Conversely, by deleting that part, the duration is reduced. This process was repeated for synchronizing my voice with the melody.
之後Audacity整出來嘅track會放返入LMMS裏面. 最後首歌係用LMMS generate出來嘅.
After that, the vocal track generated by Audacity was imported into the LMMS project. Finally, the song was generated by LMMS.
After the completion of the song itself, a video for this song was produced.
The audio visualizer software used in the video used was ProjectM. It is a real time audio visualizer. The visualization were recorded using SimpleScreenRecorder, which supports recording OpenGL output of any program. Compared with software-based recording method, recording the OpenGL output is much more efficient. Therefore, the output video is almost lag-free.
The image of the banner was created using Inkscape. After that, it was animated using Spriter Pro. Image sequences of the animation were generated. The subtitles editor used for the video of this project was Aegisub. With this software, a subtitles file were generated. An extra image were drawn with Inkscape for the end scene that asks the viewer to subscribe my channel. Finally, the audio outputted by LMMS, the visualization of the audio, the banner image sequence and the subtitles were combined by using FFmpeg. That's it!
我係作曲新手. 呢首個我花左好多工夫, 整左成超過一個月. 如果你鐘意嘅話, 麻煩幫忙share一下. 如果你地鐘意, 我日後會整多D呢類嘅歌. 多謝支持!
I'm rather new in song production. More than a month of work was spent on producing this song. If you enjoyed it, please take a moment to share it. Similar songs will be produced if the reception of this one is good. Thank you very much! :)
除此之外, 我都歡迎未來合作. 如果你有興趣, 可以send封email俾我架(email見網頁頂部)!
In addition, future collaboration is welcomed. Feel free to drop me a line by using the email address on this website.