about summary refs log tree commit diff
diff options
context:
space:
mode:
authoroy <Tom_Adams@web.de>2011-02-12 19:10:45 +0100
committeroy <Tom_Adams@web.de>2011-02-12 19:10:45 +0100
commitd12db45c488bb72558b2baa049abae7abfd9b7f3 (patch)
tree5862396448453ec98d5a40db43bab1bc89b78c6c
parentc2ad73cfe83dfdadd5500bdb909f1d3809a1963f (diff)
downloadzcatch-d12db45c488bb72558b2baa049abae7abfd9b7f3.tar.gz
zcatch-d12db45c488bb72558b2baa049abae7abfd9b7f3.zip
added editor function to construct different game tiles from a layer. Closes #460
-rw-r--r--data/languages/bosnian.txt22
-rw-r--r--data/languages/czech.txt22
-rw-r--r--data/languages/dutch.txt30
-rw-r--r--data/languages/finnish.txt22
-rw-r--r--data/languages/french.txt30
-rw-r--r--data/languages/german.txt30
-rw-r--r--data/languages/italian.txt30
-rw-r--r--data/languages/polish.txt30
-rw-r--r--data/languages/portuguese.txt22
-rw-r--r--data/languages/romanian.txt30
-rw-r--r--data/languages/russian.txt30
-rw-r--r--data/languages/serbian.txt22
-rw-r--r--data/languages/spanish.txt30
-rw-r--r--data/languages/swedish.txt22
-rw-r--r--data/languages/ukrainian.txt30
-rw-r--r--src/game/editor/ed_editor.h4
-rw-r--r--src/game/editor/ed_layer_tiles.cpp37
-rw-r--r--src/game/editor/ed_popups.cpp33
18 files changed, 291 insertions, 185 deletions
diff --git a/data/languages/bosnian.txt b/data/languages/bosnian.txt
index c8806356..f34536fe 100644
--- a/data/languages/bosnian.txt
+++ b/data/languages/bosnian.txt
@@ -570,7 +570,7 @@ CW
 Cancel
 == 
 
-Clear collision
+Clear
 == 
 
 Clip H
@@ -585,6 +585,9 @@ Clip X
 Clip Y
 == 
 
+Collision
+== 
+
 Color
 == 
 
@@ -597,7 +600,7 @@ Color TO
 Color+
 == 
 
-Constructs collision from this layer
+Constructs game tiles from this layer
 == 
 
 Creates a new color envelope
@@ -615,6 +618,9 @@ Creates a new quad layer
 Creates a new tile layer
 == 
 
+Death
+== 
+
 Decrease
 == 
 
@@ -678,6 +684,9 @@ File: %s
 Filename:
 == 
 
+Game tiles
+== 
+
 Green value of the envelope
 == 
 
@@ -726,9 +735,6 @@ Load a new image to use in the map
 Load map
 == 
 
-Make collision
-== 
-
 Make external
 == 
 
@@ -810,9 +816,6 @@ Refocus
 Remove
 == 
 
-Removes collision from this layer
-== 
-
 Removes the image from the map
 == 
 
@@ -903,6 +906,9 @@ Toggles the envelope editor.
 Unable to delete the demo
 == 
 
+Unhookable
+== 
+
 Up
 == 
 
diff --git a/data/languages/czech.txt b/data/languages/czech.txt
index 9b39066a..5d68ab2c 100644
--- a/data/languages/czech.txt
+++ b/data/languages/czech.txt
@@ -519,7 +519,7 @@ CW
 Cancel
 == 
 
-Clear collision
+Clear
 == 
 
 Clip H
@@ -534,6 +534,9 @@ Clip X
 Clip Y
 == 
 
+Collision
+== 
+
 Color
 == 
 
@@ -549,7 +552,7 @@ Color+
 Connection Problems...
 == 
 
-Constructs collision from this layer
+Constructs game tiles from this layer
 == 
 
 Creates a new color envelope
@@ -567,6 +570,9 @@ Creates a new quad layer
 Creates a new tile layer
 == 
 
+Death
+== 
+
 Decrease
 == 
 
@@ -645,6 +651,9 @@ Filename:
 Folder
 == 
 
+Game tiles
+== 
+
 Green value of the envelope
 == 
 
@@ -696,9 +705,6 @@ Load a new image to use in the map
 Load map
 == 
 
-Make collision
-== 
-
 Make external
 == 
 
@@ -798,9 +804,6 @@ Refocus
 Remove
 == 
 
-Removes collision from this layer
-== 
-
 Removes the image from the map
 == 
 
@@ -900,6 +903,9 @@ Toggles the envelope editor.
 Unable to delete the demo
 == 
 
+Unhookable
+== 
+
 Up
 == 
 
diff --git a/data/languages/dutch.txt b/data/languages/dutch.txt
index ccd9fc04..d547b81b 100644
--- a/data/languages/dutch.txt
+++ b/data/languages/dutch.txt
@@ -124,9 +124,6 @@ Cancel
 Chat
 == Chat
 
-Clear collision
-== Verwijder botsingen
-
 Clip H
 == Clip H
 
@@ -169,9 +166,6 @@ Connection Problems...
 Console
 == Console
 
-Constructs collision from this layer
-== Maakt deze laag botsend
-
 Controls
 == Besturing
 
@@ -457,9 +451,6 @@ Loading
 MOTD
 == MOTD
 
-Make collision
-== Maak botsend
-
 Make external
 == Maak extern
 
@@ -658,9 +649,6 @@ Remote console
 Remove
 == Verwijder
 
-Removes collision from this layer
-== Verwijdert botsingen in deze laag
-
 Removes the image from the map
 == Verwijdert de afbeelding uit de kaart
 
@@ -972,5 +960,23 @@ no limit
 
 ##### needs translation #####
 
+Clear
+== 
+
+Collision
+== 
+
+Constructs game tiles from this layer
+== 
+
+Death
+== 
+
+Game tiles
+== 
+
+Unhookable
+== 
+
 ##### old translations #####
 
diff --git a/data/languages/finnish.txt b/data/languages/finnish.txt
index f97a10e5..dc709c90 100644
--- a/data/languages/finnish.txt
+++ b/data/languages/finnish.txt
@@ -543,7 +543,7 @@ CW
 Cancel
 == 
 
-Clear collision
+Clear
 == 
 
 Clip H
@@ -558,6 +558,9 @@ Clip X
 Clip Y
 == 
 
+Collision
+== 
+
 Color
 == 
 
@@ -570,7 +573,7 @@ Color TO
 Color+
 == 
 
-Constructs collision from this layer
+Constructs game tiles from this layer
 == 
 
 Creates a new color envelope
@@ -588,6 +591,9 @@ Creates a new quad layer
 Creates a new tile layer
 == 
 
+Death
+== 
+
 Decrease
 == 
 
@@ -657,6 +663,9 @@ Filename:
 Folder
 == 
 
+Game tiles
+== 
+
 Green value of the envelope
 == 
 
@@ -708,9 +717,6 @@ Load a new image to use in the map
 Load map
 == 
 
-Make collision
-== 
-
 Make external
 == 
 
@@ -807,9 +813,6 @@ Refocus
 Remove
 == 
 
-Removes collision from this layer
-== 
-
 Removes the image from the map
 == 
 
@@ -903,6 +906,9 @@ Toggles the envelope editor.
 Unable to delete the demo
 == 
 
+Unhookable
+== 
+
 Up
 == 
 
diff --git a/data/languages/french.txt b/data/languages/french.txt
index af06295f..fffcb6fa 100644
--- a/data/languages/french.txt
+++ b/data/languages/french.txt
@@ -109,9 +109,6 @@ Cancel
 Chat
 == Chat
 
-Clear collision
-== Nettoyer la collision
-
 Close
 == Fermer
 
@@ -142,9 +139,6 @@ Connection Problems...
 Console
 == Console
 
-Constructs collision from this layer
-== Fait la collision depuis cette couche
-
 Controls
 == Contrôles
 
@@ -409,9 +403,6 @@ Loading
 MOTD
 == MOTD
 
-Make collision
-== Faire la collision
-
 Make external
 == Mettre en externe
 
@@ -586,9 +577,6 @@ Remote console
 Remove
 == Enlever
 
-Removes collision from this layer
-== Enlève la collision depuis cette couche
-
 Removes the image from the map
 == Enlève l'image de la carte
 
@@ -840,6 +828,9 @@ Adds a new quad
 Aspect ratio
 == 
 
+Clear
+== 
+
 Clip H
 == 
 
@@ -852,12 +843,21 @@ Clip X
 Clip Y
 == 
 
+Collision
+== 
+
+Constructs game tiles from this layer
+== 
+
 Creates a new quad layer
 == 
 
 Creates a new tile layer
 == 
 
+Death
+== 
+
 Deletes the current quad
 == 
 
@@ -867,6 +867,9 @@ Enable/disable group for saving
 Enable/disable layer for saving
 == 
 
+Game tiles
+== 
+
 HD
 == 
 
@@ -936,6 +939,9 @@ Toggles the envelope editor.
 Unable to delete the demo
 == 
 
+Unhookable
+== 
+
 Use Clipping
 == 
 
diff --git a/data/languages/german.txt b/data/languages/german.txt
index ebb5403b..602b7f5e 100644
--- a/data/languages/german.txt
+++ b/data/languages/german.txt
@@ -124,9 +124,6 @@ Cancel
 Chat
 == Chat
 
-Clear collision
-== Kollision löschen
-
 Clip H
 == Aussch. H
 
@@ -169,9 +166,6 @@ Connection Problems...
 Console
 == Konsole
 
-Constructs collision from this layer
-== Erstellt die Kollision aus dieser Ebene
-
 Controls
 == Steuerung
 
@@ -457,9 +451,6 @@ Loading
 MOTD
 == Nachricht des Tages
 
-Make collision
-== Kollision erstellen
-
 Make external
 == Extern machen
 
@@ -658,9 +649,6 @@ Remote console
 Remove
 == Entfernen
 
-Removes collision from this layer
-== Entfernt die Kollision aus dieser Ebene
-
 Removes the image from the map
 == Entfernt die Grafik aus der Karte
 
@@ -972,5 +960,23 @@ no limit
 
 ##### needs translation #####
 
+Clear
+== 
+
+Collision
+== 
+
+Constructs game tiles from this layer
+== 
+
+Death
+== 
+
+Game tiles
+== 
+
+Unhookable
+== 
+
 ##### old translations #####
 
diff --git a/data/languages/italian.txt b/data/languages/italian.txt
index 66fc1057..83414241 100644
--- a/data/languages/italian.txt
+++ b/data/languages/italian.txt
@@ -124,9 +124,6 @@ Cancel
 Chat
 == Chat
 
-Clear collision
-== Cancella collisioni
-
 Clip H
 == Alt. Taglio
 
@@ -169,9 +166,6 @@ Connection Problems...
 Console
 == Console
 
-Constructs collision from this layer
-== Costruisce le collisioni su questo livello
-
 Controls
 == Controlli
 
@@ -448,9 +442,6 @@ Loading
 MOTD
 == MDG
 
-Make collision
-== Ricalca collisioni
-
 Make external
 == Scorpora
 
@@ -640,9 +631,6 @@ Remote console
 Remove
 == Rimuovi
 
-Removes collision from this layer
-== Rimuove le collisioni presenti in questo livello
-
 Removes the image from the map
 == Rivuove l'immagine dalla mappa
 
@@ -942,12 +930,27 @@ no limit
 
 ##### needs translation #####
 
+Clear
+== 
+
+Collision
+== 
+
+Constructs game tiles from this layer
+== 
+
+Death
+== 
+
 File
 == 
 
 File: %s
 == 
 
+Game tiles
+== 
+
 HD
 == 
 
@@ -969,6 +972,9 @@ Sound error
 Sudden Death
 == 
 
+Unhookable
+== 
+
 Warmup
 == 
 
diff --git a/data/languages/polish.txt b/data/languages/polish.txt
index 9c693e2d..c589fc77 100644
--- a/data/languages/polish.txt
+++ b/data/languages/polish.txt
@@ -91,9 +91,6 @@ Cancel
 Chat
 == Chat
 
-Clear collision
-== Wyczyść kolizję
-
 Close
 == Zamknij
 
@@ -121,9 +118,6 @@ Connection Problems...
 Console
 == Konsola
 
-Constructs collision from this layer
-== Tworzy kolizję z tej warstwy
-
 Controls
 == Sterowanie
 
@@ -367,9 +361,6 @@ Loading
 MOTD
 == Wiadomość dnia
 
-Make collision
-== Stwórz kolizję
-
 Make external
 == Użyj jako zewnętrzny
 
@@ -523,9 +514,6 @@ Remote console
 Remove
 == Usuń
 
-Removes collision from this layer
-== Usuwa kolizję z tej warstwy
-
 Removes the image from the map
 == Usuwa obrazek z mapy
 
@@ -813,6 +801,9 @@ Automatically take game over screenshot
 Blue value of the envelope
 == 
 
+Clear
+== 
+
 Clip H
 == 
 
@@ -825,9 +816,18 @@ Clip X
 Clip Y
 == 
 
+Collision
+== 
+
 Color
 == 
 
+Constructs game tiles from this layer
+== 
+
+Death
+== 
+
 Delete demo
 == 
 
@@ -852,6 +852,9 @@ File: %s
 Folder
 == 
 
+Game tiles
+== 
+
 Green value of the envelope
 == 
 
@@ -948,6 +951,9 @@ Time limit: %d min
 Unable to delete the demo
 == 
 
+Unhookable
+== 
+
 Up
 == 
 
diff --git a/data/languages/portuguese.txt b/data/languages/portuguese.txt
index db7beab2..507a3eef 100644
--- a/data/languages/portuguese.txt
+++ b/data/languages/portuguese.txt
@@ -540,7 +540,7 @@ CW
 Cancel
 == 
 
-Clear collision
+Clear
 == 
 
 Clip H
@@ -555,6 +555,9 @@ Clip X
 Clip Y
 == 
 
+Collision
+== 
+
 Color
 == 
 
@@ -567,7 +570,7 @@ Color TO
 Color+
 == 
 
-Constructs collision from this layer
+Constructs game tiles from this layer
 == 
 
 Creates a new color envelope
@@ -585,6 +588,9 @@ Creates a new quad layer
 Creates a new tile layer
 == 
 
+Death
+== 
+
 Decrease
 == 
 
@@ -657,6 +663,9 @@ Filename:
 Folder
 == 
 
+Game tiles
+== 
+
 Green value of the envelope
 == 
 
@@ -708,9 +717,6 @@ Load a new image to use in the map
 Load map
 == 
 
-Make collision
-== 
-
 Make external
 == 
 
@@ -807,9 +813,6 @@ Refocus
 Remove
 == 
 
-Removes collision from this layer
-== 
-
 Removes the image from the map
 == 
 
@@ -903,6 +906,9 @@ Toggles the envelope editor.
 Unable to delete the demo
 == 
 
+Unhookable
+== 
+
 Up
 == 
 
diff --git a/data/languages/romanian.txt b/data/languages/romanian.txt
index e44bf2d0..c20fb401 100644
--- a/data/languages/romanian.txt
+++ b/data/languages/romanian.txt
@@ -124,9 +124,6 @@ Cancel
 Chat
 == Chat
 
-Clear collision
-== Curăță coliziunea
-
 Clip H
 == Î clip
 
@@ -169,9 +166,6 @@ Connection Problems...
 Console
 == Consolă
 
-Constructs collision from this layer
-== Construiește coliziunea din acest strat
-
 Controls
 == Controale
 
@@ -457,9 +451,6 @@ Loading
 MOTD
 == Mesajul zilei
 
-Make collision
-== Creează coliziunea
-
 Make external
 == Fă-o externă
 
@@ -658,9 +649,6 @@ Remote console
 Remove
 == Elimină
 
-Removes collision from this layer
-== Elimină coliziunea din acest strat
-
 Removes the image from the map
 == Elimină imaginea din hartă
 
@@ -972,5 +960,23 @@ no limit
 
 ##### needs translation #####
 
+Clear
+== 
+
+Collision
+== 
+
+Constructs game tiles from this layer
+== 
+
+Death
+== 
+
+Game tiles
+== 
+
+Unhookable
+== 
+
 ##### old translations #####
 
diff --git a/data/languages/russian.txt b/data/languages/russian.txt
index d708923d..6b97f09f 100644
--- a/data/languages/russian.txt
+++ b/data/languages/russian.txt
@@ -94,9 +94,6 @@ Cancel
 Chat
 == Чат
 
-Clear collision
-== Очистить коллизии
-
 Close
 == Закрыть
 
@@ -124,9 +121,6 @@ Connection Problems...
 Console
 == Консоль
 
-Constructs collision from this layer
-== Создать коллизии из этого слоя
-
 Controls
 == Управление
 
@@ -376,9 +370,6 @@ Loading
 MOTD
 == MOTD
 
-Make collision
-== Создать коллизии
-
 Make external
 == Сделать внешним
 
@@ -538,9 +529,6 @@ Remote console
 Remove
 == Удалить
 
-Removes collision from this layer
-== Удалить коллизии из этого слоя
-
 Removes the image from the map
 == Удалить изображение из карты
 
@@ -825,6 +813,9 @@ Automatically take game over screenshot
 Blue value of the envelope
 == 
 
+Clear
+== 
+
 Clip H
 == 
 
@@ -837,9 +828,18 @@ Clip X
 Clip Y
 == 
 
+Collision
+== 
+
 Color
 == 
 
+Constructs game tiles from this layer
+== 
+
+Death
+== 
+
 Delete demo
 == 
 
@@ -861,6 +861,9 @@ File: %s
 Folder
 == 
 
+Game tiles
+== 
+
 Green value of the envelope
 == 
 
@@ -948,6 +951,9 @@ Time limit: %d min
 Unable to delete the demo
 == 
 
+Unhookable
+== 
+
 Up
 == 
 
diff --git a/data/languages/serbian.txt b/data/languages/serbian.txt
index 54445eba..6df4962c 100644
--- a/data/languages/serbian.txt
+++ b/data/languages/serbian.txt
@@ -543,7 +543,7 @@ CW
 Cancel
 == 
 
-Clear collision
+Clear
 == 
 
 Clip H
@@ -558,6 +558,9 @@ Clip X
 Clip Y
 == 
 
+Collision
+== 
+
 Color
 == 
 
@@ -570,7 +573,7 @@ Color TO
 Color+
 == 
 
-Constructs collision from this layer
+Constructs game tiles from this layer
 == 
 
 Creates a new color envelope
@@ -588,6 +591,9 @@ Creates a new quad layer
 Creates a new tile layer
 == 
 
+Death
+== 
+
 Decrease
 == 
 
@@ -657,6 +663,9 @@ Filename:
 Folder
 == 
 
+Game tiles
+== 
+
 Green value of the envelope
 == 
 
@@ -708,9 +717,6 @@ Load a new image to use in the map
 Load map
 == 
 
-Make collision
-== 
-
 Make external
 == 
 
@@ -807,9 +813,6 @@ Refocus
 Remove
 == 
 
-Removes collision from this layer
-== 
-
 Removes the image from the map
 == 
 
@@ -903,6 +906,9 @@ Toggles the envelope editor.
 Unable to delete the demo
 == 
 
+Unhookable
+== 
+
 Up
 == 
 
diff --git a/data/languages/spanish.txt b/data/languages/spanish.txt
index 4896f434..e767d500 100644
--- a/data/languages/spanish.txt
+++ b/data/languages/spanish.txt
@@ -124,9 +124,6 @@ Cancel
 Chat
 == Charla
 
-Clear collision
-== Limpiar colisión
-
 Clip H
 == Clip H
 
@@ -169,9 +166,6 @@ Connection Problems...
 Console
 == Consola
 
-Constructs collision from this layer
-== Construir collisión para esta capa
-
 Controls
 == Controles
 
@@ -457,9 +451,6 @@ Loading
 MOTD
 == MOTD
 
-Make collision
-== Fabricar colisión
-
 Make external
 == Fabricar exterior
 
@@ -658,9 +649,6 @@ Remote console
 Remove
 == Remover
 
-Removes collision from this layer
-== Remover colisión para esta capa
-
 Removes the image from the map
 == Remover la imagen de este mapa
 
@@ -972,5 +960,23 @@ no limit
 
 ##### needs translation #####
 
+Clear
+== 
+
+Collision
+== 
+
+Constructs game tiles from this layer
+== 
+
+Death
+== 
+
+Game tiles
+== 
+
+Unhookable
+== 
+
 ##### old translations #####
 
diff --git a/data/languages/swedish.txt b/data/languages/swedish.txt
index 4ee8e04d..29184e95 100644
--- a/data/languages/swedish.txt
+++ b/data/languages/swedish.txt
@@ -513,7 +513,7 @@ CW
 Cancel
 == 
 
-Clear collision
+Clear
 == 
 
 Clip H
@@ -528,6 +528,9 @@ Clip X
 Clip Y
 == 
 
+Collision
+== 
+
 Color
 == 
 
@@ -543,7 +546,7 @@ Color+
 Connection Problems...
 == 
 
-Constructs collision from this layer
+Constructs game tiles from this layer
 == 
 
 Creates a new color envelope
@@ -561,6 +564,9 @@ Creates a new quad layer
 Creates a new tile layer
 == 
 
+Death
+== 
+
 Decrease
 == 
 
@@ -642,6 +648,9 @@ Folder
 Force vote
 == 
 
+Game tiles
+== 
+
 Green value of the envelope
 == 
 
@@ -693,9 +702,6 @@ Load a new image to use in the map
 Load map
 == 
 
-Make collision
-== 
-
 Make external
 == 
 
@@ -795,9 +801,6 @@ Refocus
 Remove
 == 
 
-Removes collision from this layer
-== 
-
 Removes the image from the map
 == 
 
@@ -897,6 +900,9 @@ Toggles the envelope editor.
 Unable to delete the demo
 == 
 
+Unhookable
+== 
+
 Up
 == 
 
diff --git a/data/languages/ukrainian.txt b/data/languages/ukrainian.txt
index c526600c..ad5982ab 100644
--- a/data/languages/ukrainian.txt
+++ b/data/languages/ukrainian.txt
@@ -100,9 +100,6 @@ Cancel
 Chat
 == Чат
 
-Clear collision
-== Очистити колізію
-
 Close
 == Закрити
 
@@ -130,9 +127,6 @@ Connection Problems...
 Console
 == Консоль
 
-Constructs collision from this layer
-== Створити колізії з цього шару
-
 Controls
 == Управління
 
@@ -400,9 +394,6 @@ Loading
 MOTD
 == MOTD
 
-Make collision
-== Створити колізії
-
 Make external
 == Зробити зовнішнім
 
@@ -568,9 +559,6 @@ Remote console
 Remove
 == Видалити
 
-Removes collision from this layer
-== Видалити колізії з цього шару
-
 Removes the image from the map
 == Видалити зображення з карти
 
@@ -873,6 +861,9 @@ Automatically take game over screenshot
 Blue value of the envelope
 == 
 
+Clear
+== 
+
 Clip H
 == 
 
@@ -885,9 +876,18 @@ Clip X
 Clip Y
 == 
 
+Collision
+== 
+
 Color
 == 
 
+Constructs game tiles from this layer
+== 
+
+Death
+== 
+
 Delete demo
 == 
 
@@ -897,6 +897,9 @@ Delete this envelope
 File: %s
 == 
 
+Game tiles
+== 
+
 Green value of the envelope
 == 
 
@@ -954,6 +957,9 @@ The audio device couldn't be initialised.
 Unable to delete the demo
 == 
 
+Unhookable
+== 
+
 Up
 == 
 
diff --git a/src/game/editor/ed_editor.h b/src/game/editor/ed_editor.h
index 461cdeed..007e94f1 100644
--- a/src/game/editor/ed_editor.h
+++ b/src/game/editor/ed_editor.h
@@ -653,12 +653,16 @@ public:
 	static int PopupQuad(CEditor *pEditor, CUIRect View);
 	static int PopupPoint(CEditor *pEditor, CUIRect View);
 	static int PopupSelectImage(CEditor *pEditor, CUIRect View);
+	static int PopupSelectGametileOp(CEditor *pEditor, CUIRect View);
 	static int PopupImage(CEditor *pEditor, CUIRect View);
 	static int PopupMenuFile(CEditor *pEditor, CUIRect View);
 
 
 	void PopupSelectImageInvoke(int Current, float x, float y);
 	int PopupSelectImageResult();
+
+	void PopupSelectGametileOpInvoke(float x, float y);
+	int PopupSelectGameTileOpResult();
 	
 	vec4 ButtonColorMul(const void *pId);
 
diff --git a/src/game/editor/ed_layer_tiles.cpp b/src/game/editor/ed_layer_tiles.cpp
index 71489d7c..6ef2d256 100644
--- a/src/game/editor/ed_layer_tiles.cpp
+++ b/src/game/editor/ed_layer_tiles.cpp
@@ -333,41 +333,20 @@ int CLayerTiles::RenderProperties(CUIRect *pToolBox)
 	if(InGameGroup)
 	{
 		static int s_ColclButton = 0;
-		if(m_pEditor->DoButton_Editor(&s_ColclButton, Localize("Clear collision"), 0, &Button, 0, Localize("Removes collision from this layer")))
-		{
-			CLayerTiles *gl = m_pEditor->m_Map.m_pGameLayer;
-			int w = min(gl->m_Width, m_Width);
-			int h = min(gl->m_Height, m_Height);
-			for(int y = 0; y < h; y++)
-			{
-				for(int x = 0; x < w; x++)
-				{
-					if(gl->m_pTiles[y*gl->m_Width+x].m_Index <= TILE_SOLID)
-					{
-						if(m_pTiles[y*m_Width+x].m_Index)
-							gl->m_pTiles[y*gl->m_Width+x].m_Index = TILE_AIR;
-					}
-				}
-			}
-			return 1;
-		}
-		
-		static int s_ColButton = 0;
-		pToolBox->HSplitBottom(5.0f, pToolBox, &Button);
-		pToolBox->HSplitBottom(12.0f, pToolBox, &Button);
-		if(m_pEditor->DoButton_Editor(&s_ColButton, Localize("Make collision"), 0, &Button, 0, Localize("Constructs collision from this layer")))
+		if(m_pEditor->DoButton_Editor(&s_ColclButton, Localize("Game tiles"), 0, &Button, 0, Localize("Constructs game tiles from this layer")))
+			m_pEditor->PopupSelectGametileOpInvoke(m_pEditor->UI()->MouseX(), m_pEditor->UI()->MouseY());
+
+		int Result = m_pEditor->PopupSelectGameTileOpResult();
+		if(Result > -1)
 		{
 			CLayerTiles *gl = m_pEditor->m_Map.m_pGameLayer;
 			int w = min(gl->m_Width, m_Width);
 			int h = min(gl->m_Height, m_Height);
 			for(int y = 0; y < h; y++)
-			{
 				for(int x = 0; x < w; x++)
-				{
-					if(gl->m_pTiles[y*gl->m_Width+x].m_Index <= TILE_SOLID)
-						gl->m_pTiles[y*gl->m_Width+x].m_Index = m_pTiles[y*m_Width+x].m_Index?TILE_SOLID:TILE_AIR;
-				}
-			}
+					if(gl->m_pTiles[y*gl->m_Width+x].m_Index >= TILE_AIR && gl->m_pTiles[y*gl->m_Width+x].m_Index <= TILE_NOHOOK)
+						gl->m_pTiles[y*gl->m_Width+x].m_Index = m_pTiles[y*m_Width+x].m_Index?TILE_AIR+Result:TILE_AIR;
+
 			return 1;
 		}
 	}
diff --git a/src/game/editor/ed_popups.cpp b/src/game/editor/ed_popups.cpp
index 2054e67f..c0fcc5d5 100644
--- a/src/game/editor/ed_popups.cpp
+++ b/src/game/editor/ed_popups.cpp
@@ -470,7 +470,40 @@ int CEditor::PopupSelectImageResult()
 	return g_SelectImageCurrent;
 }
 
+static int s_GametileOpSelected = -1;
 
+int CEditor::PopupSelectGametileOp(CEditor *pEditor, CUIRect View)
+{
+	/*	This is for scripts/update_localization.py to work, don't remove!
+		Localize("Clear"); Localize("Collision"); Localize("Death"); Localize("Unhookable"); */
+	static const char *s_pButtonNames[] = { "Clear", "Collision", "Death", "Unhookable" };
+	static unsigned s_NumButtons = sizeof(s_pButtonNames) / sizeof(char*);
+	CUIRect Button;
+
+	for(unsigned i = 0; i < s_NumButtons; ++i)
+	{
+		View.HSplitTop(2.0f, 0, &View);
+		View.HSplitTop(12.0f, &Button, &View);
+		if(pEditor->DoButton_Editor(&s_pButtonNames[i], Localize(s_pButtonNames[i]), 0, &Button, 0, 0))
+			s_GametileOpSelected = i;
+	}
 
+	return 0;
+}
 
+void CEditor::PopupSelectGametileOpInvoke(float x, float y)
+{
+	static int s_SelectGametileOpPopupId = 0;
+	s_GametileOpSelected = -1;
+	UiInvokePopupMenu(&s_SelectGametileOpPopupId, 0, x, y, 120.0f, 70.0f, PopupSelectGametileOp);
+}
 
+int CEditor::PopupSelectGameTileOpResult()
+{
+	if(s_GametileOpSelected < 0)
+		return -1;
+	
+	int Result = s_GametileOpSelected;
+	s_GametileOpSelected = -1;
+	return Result;
+}