2 from .utils import make_flask_user_password
6 admin_user = User("rubenwardy")
7 admin_user.active = True
8 admin_user.password = make_flask_user_password("tuckfrump")
9 admin_user.github_username = "rubenwardy"
10 admin_user.forums_username = "rubenwardy"
11 admin_user.rank = UserRank.ADMIN
12 session.add(admin_user)
14 session.add(MinetestRelease("None", 0))
15 session.add(MinetestRelease("0.4.16/17", 32))
16 session.add(MinetestRelease("5.0", 37))
17 session.add(MinetestRelease("5.1", 38))
20 for tag in ["Inventory", "Mapgen", "Building", \
21 "Mobs and NPCs", "Tools", "Player effects", \
22 "Environment", "Transport", "Maintenance", "Plants and farming", \
23 "PvP", "PvE", "Survival", "Creative", "Puzzle", "Multiplayer", "Singleplayer"]:
29 for license in ["GPLv2.1", "GPLv3", "LGPLv2.1", "LGPLv3", "AGPLv2.1", "AGPLv3",
30 "Apache", "BSD 3-Clause", "BSD 2-Clause", "CC0", "CC-BY-SA",
31 "CC-BY", "MIT", "ZLib", "Other (Free)"]:
32 row = License(license)
33 licenses[row.name] = row
36 for license in ["CC-BY-NC-SA", "Other (Non-free)"]:
37 row = License(license, False)
38 licenses[row.name] = row
42 def populate_test_data(session):
43 licenses = { x.name : x for x in License.query.all() }
44 tags = { x.name : x for x in Tag.query.all() }
45 admin_user = User.query.filter_by(rank=UserRank.ADMIN).first()
46 v4 = MinetestRelease.query.filter_by(protocol=32).first()
47 v50 = MinetestRelease.query.filter_by(protocol=37).first()
48 v51 = MinetestRelease.query.filter_by(protocol=38).first()
51 ez.github_username = "Ezhh"
52 ez.forums_username = "Shara"
53 ez.rank = UserRank.EDITOR
56 not1 = Notification(admin_user, ez, "Awards approved", "/packages/rubenwardy/awards/")
60 jeija.github_username = "Jeija"
61 jeija.forums_username = "Jeija"
68 mod.title = "Alpha Test"
69 mod.license = licenses["MIT"]
70 mod.media_license = licenses["MIT"]
71 mod.type = PackageType.MOD
72 mod.author = admin_user
73 mod.tags.append(tags["mapgen"])
74 mod.tags.append(tags["environment"])
75 mod.repo = "https://github.com/ezhh/other_worlds"
76 mod.issueTracker = "https://github.com/ezhh/other_worlds/issues"
78 mod.short_desc = "The content library should not be used yet as it is still in alpha"
79 mod.desc = "This is the long desc"
82 rel = PackageRelease()
85 rel.url = "https://github.com/ezhh/handholds/archive/master.zip"
93 mod1.license = licenses["LGPLv2.1"]
94 mod1.media_license = licenses["MIT"]
95 mod1.type = PackageType.MOD
96 mod1.author = admin_user
97 mod1.tags.append(tags["player_effects"])
98 mod1.repo = "https://github.com/rubenwardy/awards"
99 mod1.issueTracker = "https://github.com/rubenwardy/awards/issues"
101 mod1.short_desc = "Adds achievements and an API to register new ones."
103 Majority of awards are back ported from Calinou's old fork in Carbone, under same license.
106 awards.register_achievement("award_mesefind",{
107 title = "First Mese Find",
108 description = "Found some Mese!",
110 type = "dig", -- award is given when
111 node = "default:mese", -- this type of node has been dug
112 target = 1, -- this number of times
118 rel = PackageRelease()
122 rel.url = "https://github.com/rubenwardy/awards/archive/master.zip"
128 mod2.name = "mesecons"
129 mod2.title = "Mesecons"
130 mod2.tags.append(tags["tools"])
131 mod2.type = PackageType.MOD
132 mod2.license = licenses["LGPLv3"]
133 mod2.media_license = licenses["MIT"]
135 mod2.repo = "https://github.com/minetest-mods/mesecons/"
136 mod2.issueTracker = "https://github.com/minetest-mods/mesecons/issues"
138 mod2.short_desc = "Mesecons adds everything digital, from all kinds of sensors, switches, solar panels, detectors, pistons, lamps, sound blocks to advanced digital circuitry like logic gates and programmable blocks."
140 MESECONS by Jeija and contributors
144 [Mesecons](http://mesecons.net/)! They're yellow, they're conductive, and they'll add a whole new dimension to Minetest's gameplay.
146 Mesecons is a mod for [Minetest](http://minetest.net/) that implements a ton of items related to digital circuitry, such as wires, buttons, lights, and even programmable controllers. Among other things, there are also pistons, solar panels, pressure plates, and note blocks.
148 Mesecons has a similar goal to Redstone in Minecraft, but works in its own way, with different rules and mechanics.
154 [DOWNLOAD IT NOW](https://github.com/minetest-mods/mesecons/archive/master.zip)
156 Now go ahead and install it like any other Minetest mod. Don't know how? Check out [the wonderful page about it](http://wiki.minetest.com/wiki/Mods) over at the Minetest Wiki. For your convenience, here's a quick summary:
158 1. If Mesecons is still in a ZIP file, extract the folder inside to somewhere on the computer.
159 2. Make sure that when you open the folder, you can directly find `README.md` in the listing. If you just see another folder, move that folder up one level and delete the old one.
160 3. Open up the Minetest mods folder - usually `/mods/`. If you see the `minetest` or folder inside of that, that is your mod folder instead.
161 4. Copy the Mesecons folder into the mods folder.
163 Don't like some parts of Mesecons? Open up the Mesecons folder and delete the subfolder containing the mod you don't want. If you didn't want movestones, for example, all you have to do is delete the `mesecons_movestones` folder and they will no longer be available.
165 There are no dependencies - it will work right after installing!
167 How do I use this thing?
168 ------------------------
169 How about a [quick overview video](https://www.youtube.com/watch?v=6kmeQj6iW5k)?
171 Or maybe a [comprehensive reference](http://mesecons.net/items.html) is your style?
173 An overview for the very newest of new beginners? How does [this one](http://uberi.mesecons.net/projects/MeseconsBasics/index.html) look?
175 Want to get more into building? Why not check out the [Mesecons Laboratory](http://uberi.mesecons.net/), a website dedicated to advanced Mesecons builders?
177 Want to contribute to Mesecons itself? Check out the [source code](https://github.com/minetest-mods/mesecons)!
179 Who wrote it anyways?
180 ---------------------
181 These awesome people made Mesecons possible!
183 | Contributor | Contribution |
184 | --------------- | -------------------------------- |
185 | Hawk777 | Code for VoxelManip caching |
186 | Jat15 | Various tweaks. |
187 | Jeija | **Main developer! Everything.** |
188 | Jordach | Noteblock sounds. |
189 | khonkhortistan | Code, recipes, textures. |
190 | Kotolegokot | Nodeboxes for items. |
191 | minerd247 | Textures. |
192 | Nore/Novatux | Code. |
193 | RealBadAngel | Fixes, improvements. |
194 | sfan5 | Code, recipes, textures. |
195 | suzenako | Piston sounds. |
196 | Uberi/Temperest | Code, textures, documentation. |
197 | VanessaE | Code, recipes, textures, design. |
198 | Whiskers75 | Logic gates implementation. |
200 There are also a whole bunch of other people helping with everything from code to testing and feedback. Mesecons would also not be possible without their help!
202 Alright, how can I use it?
203 --------------------------
204 All textures in this project are licensed under the CC-BY-SA 3.0 (Creative Commons Attribution-ShareAlike 3.0 Generic). That means you can distribute and remix them as much as you want to, under the condition that you give credit to the authors and the project, and that if you remix and release them, they must be under the same or similar license to this one.
206 All code in this project is licensed under the LGPL version 3 or later. That means you have unlimited freedom to distribute and modify the work however you see fit, provided that if you decide to distribute it or any modified versions of it, you must also use the same license. The LGPL also grants the additional freedom to write extensions for the software and distribute them without the extensions being subject to the terms of the LGPL, although the software itself retains its license.
208 No warranty is provided, express or implied, for any part of the project.
217 mod.name = "handholds"
218 mod.title = "Handholds"
219 mod.license = licenses["MIT"]
220 mod.media_license = licenses["MIT"]
221 mod.type = PackageType.MOD
223 mod.tags.append(tags["player_effects"])
224 mod.repo = "https://github.com/ezhh/handholds"
225 mod.issueTracker = "https://github.com/ezhh/handholds/issues"
227 mod.short_desc = "Adds hand holds and climbing thingies"
228 mod.desc = "This is the long desc"
231 rel = PackageRelease()
235 rel.url = "https://github.com/ezhh/handholds/archive/master.zip"
241 mod.name = "other_worlds"
242 mod.title = "Other Worlds"
243 mod.license = licenses["MIT"]
244 mod.media_license = licenses["MIT"]
245 mod.type = PackageType.MOD
247 mod.tags.append(tags["mapgen"])
248 mod.tags.append(tags["environment"])
249 mod.repo = "https://github.com/ezhh/other_worlds"
250 mod.issueTracker = "https://github.com/ezhh/other_worlds/issues"
252 mod.short_desc = "Adds space with asteroids and comets"
253 mod.desc = "This is the long desc"
260 mod.license = licenses["LGPLv2.1"]
261 mod.media_license = licenses["MIT"]
262 mod.type = PackageType.MOD
263 mod.author = admin_user
264 mod.tags.append(tags["player_effects"])
265 mod.repo = "https://github.com/rubenwardy/food/"
266 mod.issueTracker = "https://github.com/rubenwardy/food/issues/"
268 mod.short_desc = "Adds lots of food and an API to manage ingredients"
269 mod.desc = "This is the long desc"
274 mod.name = "food_sweet"
275 mod.title = "Sweet Foods"
276 mod.license = licenses["CC0"]
277 mod.media_license = licenses["MIT"]
278 mod.type = PackageType.MOD
279 mod.author = admin_user
280 mod.tags.append(tags["player_effects"])
281 mod.repo = "https://github.com/rubenwardy/food_sweet/"
282 mod.issueTracker = "https://github.com/rubenwardy/food_sweet/issues/"
284 mod.short_desc = "Adds sweet food"
285 mod.desc = "This is the long desc"
290 game1.approved = True
291 game1.name = "capturetheflag"
292 game1.title = "Capture The Flag"
293 game1.type = PackageType.GAME
294 game1.license = licenses["LGPLv2.1"]
295 game1.media_license = licenses["MIT"]
296 game1.author = admin_user
297 game1.tags.append(tags["pvp"])
298 game1.tags.append(tags["survival"])
299 game1.tags.append(tags["multiplayer"])
300 game1.repo = "https://github.com/rubenwardy/capturetheflag"
301 game1.issueTracker = "https://github.com/rubenwardy/capturetheflag/issues"
303 game1.short_desc = "Two teams battle to snatch and return the enemy's flag, before the enemy takes their own!"
305 As seen on the Capture the Flag server (minetest.rubenwardy.com:30000)
307 ` `[`javascript:/*--></title></style></textarea></script></xmp><svg/onload='+/"/+/onmouseover=1/+/`](javascript:/*--%3E%3C/title%3E%3C/style%3E%3C/textarea%3E%3C/script%3E%3C/xmp%3E%3Csvg/onload='+/%22/+/onmouseover=1/+/)`[*/[]/+alert(1)//'>`
309 <IMG SRC="javascript:alert('XSS');">
311 <IMG SRC=javascript:alert(&quot;XSS&quot;)>
313 ``<IMG SRC=`javascript:alert("RSnake says, 'XSS'")`>``
315 \<a onmouseover="alert(document.cookie)"\>xxs link\</a\>
317 \<a onmouseover=alert(document.cookie)\>xxs link\</a\>
319 <IMG SRC=javascript:alert(String.fromCharCode(88,83,83))>
321 <script>alert("hello");</script>
323 <SCRIPT SRC=`[`http://xss.rocks/xss.js></SCRIPT>`](http://xss.rocks/xss.js%3E%3C/SCRIPT%3E)`;`
333 <IMG SRC= onmouseover="alert('xxs')">
335 <img src=x onerror="javascript:alert('XSS')">
339 Uses the CTF PvP Engine.
344 rel = PackageRelease()
347 rel.url = "https://github.com/rubenwardy/capturetheflag/archive/master.zip"
354 mod.name = "pixelbox"
355 mod.title = "PixelBOX Reloaded"
356 mod.license = licenses["CC0"]
357 mod.media_license = licenses["MIT"]
358 mod.type = PackageType.TXP
359 mod.author = admin_user
361 mod.short_desc = "This is an update of the original PixelBOX texture pack by the brillant artist Gambit"
362 mod.desc = "This is the long desc"
365 rel = PackageRelease()
368 rel.url = "http://mamadou3.free.fr/Minetest/PixelBOX.zip"
375 for package in Package.query.filter_by(type=PackageType.MOD).all():
378 meta = metas[package.name]
380 meta = MetaPackage(package.name)
382 metas[package.name] = meta
383 package.provides.append(meta)
385 dep = Dependency(food_sweet, meta=metas["food"])