It’s the time to start uploading to extension gallery. We have created two plugins so far:
I will describe the process on the example of the second one. You can find it here: https://wordpress.org/plugins/demo-shortcodes/. To install it from the dashboard, go to Plugins/Add New, change search criteria to Author and look for kantoniak.
Mouse picking can be found in nearly every 3D game now. In many cases, it’s crucial to let the user interact with the world by directly pointing at some objects. One of the possible approaches is to convert pointer position to some vector/ray inside the world and do hit-testing. To achieve this I use GLM library which handles mathematical routines for OpenGL.
Just a short note regarding recent changes in Konstruisto. I committed the last two weeks to finishing roads, I wanted to finish algorithm implementation before Easter break. Continue reading
I made a plugin to render HTML before page content (see “How do I make a WordPress plugin?“), but I needed another one. This extension adds “see demo” blocks inside content. I just give links to preview, set image and eye-pleasing blocks appear in place of shortcodes.
The extension is available from a GitHub repository; you can go there to see every line of code. I will try to send it to plugin repository shortly.
Update: Plugin is already available here: https://wordpress.org/plugins/demo-shortcodes/. To install it from the dashboard, go to Plugins/Add New, change search criteria to Author and look for kantoniak.
Demo plugin preview
OK, let’s go! Continue reading
I’m happy to have a new contributor to my project, who did some cleanup to Makefile (thanks, @buoto!). I thought it’s a good time to write a few words on how the make tool works.
Windows users: to check if you have
make installed on your machine type in your command line:
make --version. If you don’t, I suggest downloading Gow, which will equip your Windows with most useful Linux commands. Windows 10 users can use Windows Subsystem for Linux feature (how to enable).
make tool for?
Reading my tutorials, you could notice I compile many of my examples by hand, i.e. I run commands like this every time:
$ clang++ -std=c++14 timepoints.cpp -o timepoints.exe && ./timepoints.exe
It takes time, is repetitive, it’s easy to forget some option or make a typo somewhere. Another problem is, the set of commands working on one machine may not work on another because of e.g. different OS installed. Continue reading
C++11 introduces the
<chrono> library helpful to work with time spans. In this post, I go through its most important parts and show some examples.
Duration is the simplest type comprising of a ratio (e.g. 1:1000 for milliseconds) and the number of ticks. A single object is guaranteed to hold a timespan nearing 300 years. Continue reading
We would like every single page on the Internet to load instantly and be easy to use and understand. It’s only some kind of ideal, you will find problems with every page (with this one as well). It’s good to know what these problems are, at least. Let’s review some of them through simple tips. Continue reading
To move forward I started working on zoning. There is a new type of object representing a lot. Buildings will grow on these later. Currently, there is no zoning by mouse, even though option appears in the menu. Regarding roads, I started road network graph. I think I will finish intersection rendering next week. Pushed 10 commits, total 131.
I wanted to print a calendar for April, but there was no satisfying solution on the Internet. What else could I do? I wrote one using CSS flexbox model.
This week was pretty tough on me, so the update comes late. I made a bulldozer tool for buildings. All the buildings in selected area will get removed. I added the executable icon, which is also visible in the window title. There’s new menu to choose the tool, I have to create some decent icons since temporary ones are awful 🙂 Pushed 14 commits, total 121.