Dec 26, 2005 23:46
Cartographer Filters
* From DAllen's idea in the "Cartographer" thread *
Cartographer is a very good tool for map creators, even if it needs some more functions to be complete (see here to read the discussion about it). I can say to you that Ianbanks wants to continue his work on it : he just need our encouragements, to find some time, and to see that we use it ;)
The object of this thread is that Cartographer allows us to create and use Filters written in LUA.
I give here some scripts I made.
Cartographer is a very good tool for map creators, even if it needs some more functions to be complete (see here to read the discussion about it). I can say to you that Ianbanks wants to continue his work on it : he just need our encouragements, to find some time, and to see that we use it ;)
The object of this thread is that Cartographer allows us to create and use Filters written in LUA.
I give here some scripts I made.
- Create a "Filters" directory in the same directory than "Cartographer.exe".
- Copy all the content of each script in a new Notepad file. I recommend you to name the file like the 1st line of the script (without the"-- "). Don't forget the ".lua" extension when saving.
- Open Cartographer. Open Filters menu and you will see the new filters.[/list:o:c1344c573b]
*EDIT 2006-07-31 : You can download my complete collection of filters, ready to use, on my "Alain's WinBolo Micro-Site" here ;)
A simple script to understand the terrains codes :
[code:1:c1344c573b]-- Tool - Terrains Codes.lua
-- Cartographer Filter
-- By Alain
for i = 0, 16 do
line(i+5, i, i+10, i, i)
end[/code:1:c1344c573b]
The center of the square made by this 2nd filter is the absolute symmetry center of the map. Draw in a quad and then use the 4 other symmetry filters to complete the other quads.
[code:1:c1344c573b]-- Tool - Symmetry 0 Center Point.lua
-- Cartographer Filter
-- By Alain
line(127, 127, 128, 128, 4)
line(127, 128, 128, 127, 0)[/code:1:c1344c573b]
[code:1:c1344c573b]-- Tool - Symmetry 1 West-East.lua
-- Cartographer Filter
-- By Alain
for y = 0, 255 do
for x = 0, 127 do
setpoint(255-x, y, getpoint(x, y))
end
end[/code:1:c1344c573b]
[code:1:c1344c573b]-- Tool - Symmetry 2 East-West.lua
-- Cartographer Filter
-- By Alain
for y = 0, 255 do
for x = 0, 127 do
setpoint(x, y, getpoint(255-x, y))
end
end[/code:1:c1344c573b]
[code:1:c1344c573b]-- Tool - Symmetry 3 North-South.lua
-- Cartographer Filter
-- By Alain
for y = 0, 127 do
for x = 0, 255 do
setpoint(x, 255-y, getpoint(x, y))
end
end[/code:1:c1344c573b]
[code:1:c1344c573b]-- Tool - Symmetry 4 South-North.lua
-- Cartographer Filter
-- By Alain
for y = 0, 127 do
for x = 0, 255 do
setpoint(x, y, getpoint(x, 255-y))
end
end[/code:1:c1344c573b]
Some other examples of filters (some of them already posted by others and modified) :
[code:1:c1344c573b]-- Tool - Border Limits.lua
-- Cartographer Filter
-- By Alain
tile_type = OCEAN
for i = 0, 9 do
line(i, 0, i, 255, tile_type)
line(0, i, 255, i, tile_type)
line(255-i, 0, 255-i, 255, tile_type)
line(255, 255-i, 0, 255-i, tile_type)
end[/code:1:c1344c573b]
[code:1:c1344c573b]-- Background - Random Diagonals.lua
-- Cartographer Filter
-- By Alain
for n = 1, 10000 do
x = math.random() * 225 + 10
y = math.random() * 225 + 10
line(x, y, x + 10, y + 10, math.random() * 10)
end[/code:1:c1344c573b]
[code:1:c1344c573b]-- Background - Explosion.lua
-- Cartographer Filter
-- By Alain
for x = 0, 1000 do
line(127, 127, math.random(10, 245), math.random(10, 245), math.random(0, 9))
end[/code:1:c1344c573b]
Tell me if you want that I send you all these files "ready to use".
Then... if you make some interesting filters, please post them here :D[/url][/b]
Last edited: Jul 31, 2006 16:07 (edited 2 times)