From 6dff0b435a059f0c66b842673677c13bfd95f7c4 Mon Sep 17 00:00:00 2001 From: Code WvS Date: Sun, 1 Mar 2015 12:39:30 +0100 Subject: add overpass API block --- objects.js | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'objects.js') diff --git a/objects.js b/objects.js index 3bdda48..0f77351 100644 --- a/objects.js +++ b/objects.js @@ -219,12 +219,16 @@ SpriteMorph.prototype.initBlocks = function () { spec: 'lat, lon of %s', defaults: ['Tiergarten Berlin'] }, - // TODO: move these to a 'map' category or so reportGeocode: { type: 'reporter', category: 'motion', spec: 'address at lon: %n lat: %n' }, + overpassQuerySucceeds: { + type: 'predicate', + category: 'motion', + spec: 'overpass query %s returns elements' + }, focusMap: { type: 'command', category: 'motion', @@ -1778,9 +1782,14 @@ SpriteMorph.prototype.blockTemplates = function (category) { if (cat === 'motion') { blocks.push(block('userLon')); blocks.push(block('userLat')); + blocks.push('-'); + blocks.push(block('overpassQuerySucceeds')); + blocks.push('-'); blocks.push(block('reportGeocode')); blocks.push(block('findLocation')); + blocks.push('-'); blocks.push(block('focusMap')); + blocks.push('-'); //if (this.world().isDevMode) { blocks.push(block('addMarker')); -- cgit v1.3.1