diff --git a/assets_src/m03_algorithm.png b/assets_src/m03_algorithm.png new file mode 100644 index 0000000..c0020b4 Binary files /dev/null and b/assets_src/m03_algorithm.png differ diff --git a/assets_src/map_m03.png b/assets_src/map_m03.png new file mode 100644 index 0000000..e87329c Binary files /dev/null and b/assets_src/map_m03.png differ diff --git a/mods/vinylgod/fluent/lua.ftl b/mods/vinylgod/fluent/lua.ftl index 60a79d1..3072374 100644 --- a/mods/vinylgod/fluent/lua.ftl +++ b/mods/vinylgod/fluent/lua.ftl @@ -9,3 +9,8 @@ keep-the-van-alive = Do not lose the Pop-Up Shop destroy-the-transcoder = Destroy the Transcoder before the master is cut keep-the-selector-alive = The Selector must survive wipe-the-outpost = Level the whole outpost + +build-the-studio = Build a Mastering Studio +silence-the-algorithm = Silence The Algorithm +keep-the-shop-standing = Keep the Pop-Up Shop standing +it-heard-you = THE ALGORITHM HAS NOTICED YOU diff --git a/mods/vinylgod/maps/arena/map.bin b/mods/vinylgod/maps/arena/map.bin index 1c997a0..13c2776 100644 Binary files a/mods/vinylgod/maps/arena/map.bin and b/mods/vinylgod/maps/arena/map.bin differ diff --git a/mods/vinylgod/maps/compression/map.bin b/mods/vinylgod/maps/compression/map.bin index b84601b..ebbf48f 100644 Binary files a/mods/vinylgod/maps/compression/map.bin and b/mods/vinylgod/maps/compression/map.bin differ diff --git a/mods/vinylgod/maps/district/map.bin b/mods/vinylgod/maps/district/map.bin index 466d053..1d2ee11 100644 Binary files a/mods/vinylgod/maps/district/map.bin and b/mods/vinylgod/maps/district/map.bin differ diff --git a/mods/vinylgod/maps/m01/map.bin b/mods/vinylgod/maps/m01/map.bin index 53d1c78..775da4b 100644 Binary files a/mods/vinylgod/maps/m01/map.bin and b/mods/vinylgod/maps/m01/map.bin differ diff --git a/mods/vinylgod/maps/m02/map.bin b/mods/vinylgod/maps/m02/map.bin index 2179b66..4e3af20 100644 Binary files a/mods/vinylgod/maps/m02/map.bin and b/mods/vinylgod/maps/m02/map.bin differ diff --git a/mods/vinylgod/maps/m03/m03.lua b/mods/vinylgod/maps/m03/m03.lua new file mode 100644 index 0000000..1fcb121 --- /dev/null +++ b/mods/vinylgod/maps/m03/m03.lua @@ -0,0 +1,59 @@ +-- 03: THE DROP — finale. + +CounterattackDone = false +Ticks = 0 + +WorldLoaded = function() + Mrp = Player.GetPlayer("Player") + Stream = Player.GetPlayer("Enemy") + InitObjectives(Mrp) + + StudioObjective = Mrp.AddPrimaryObjective("build-the-studio") + AlgorithmObjective = Mrp.AddPrimaryObjective("silence-the-algorithm") + ShopObjective = Mrp.AddSecondaryObjective("keep-the-shop-standing") + + Trigger.OnKilled(TheAlgorithm, function() + Mrp.MarkCompletedObjective(AlgorithmObjective) + end) + + -- losing the HQ costs the secondary, not the mission + Trigger.OnKilled(TheVan, function() + Trigger.AfterDelay(DateTime.Seconds(2), function() + local hq = Utils.Where(Map.ActorsInWorld, function(a) + return a.Owner == Mrp and a.Type == "popupshop" + end) + if #hq == 0 then + Mrp.MarkFailedObjective(ShopObjective) + end + end) + end) +end + +Tick = function() + Ticks = Ticks + 1 + -- once a second is plenty; scanning every actor every frame is wasteful + if Ticks % 25 ~= 0 then + return + end + if StudioObjective == nil or Mrp.IsObjectiveCompleted(StudioObjective) then + return + end + + local studios = Utils.Where(Map.ActorsInWorld, function(a) + return a.Owner == Mrp and a.Type == "mastering" + end) + + if #studios > 0 then + Mrp.MarkCompletedObjective(StudioObjective) + if not CounterattackDone then + CounterattackDone = true + Media.DisplayMessage(UserInterface.GetFluentMessage("it-heard-you")) + Media.PlaySpeechNotification(Mrp, "BaseAttack") + Utils.Do(Map.ActorsInWorld, function(a) + if a.Owner == Stream and a.HasProperty("Hunt") then + a.Hunt() + end + end) + end + end +end diff --git a/mods/vinylgod/maps/m03/map.bin b/mods/vinylgod/maps/m03/map.bin new file mode 100644 index 0000000..46cfe91 Binary files /dev/null and b/mods/vinylgod/maps/m03/map.bin differ diff --git a/mods/vinylgod/maps/m03/map.png b/mods/vinylgod/maps/m03/map.png new file mode 100644 index 0000000..e02ee05 Binary files /dev/null and b/mods/vinylgod/maps/m03/map.png differ diff --git a/mods/vinylgod/maps/m03/map.yaml b/mods/vinylgod/maps/m03/map.yaml new file mode 100644 index 0000000..79f4495 --- /dev/null +++ b/mods/vinylgod/maps/m03/map.yaml @@ -0,0 +1,152 @@ +MapFormat: 12 + +RequiresMod: vinylgod + +Title: 03 - The Drop + +Author: Monster Robot Party + +Tileset: VINYLGOD + +MapSize: 66,66 + +Bounds: 1,1,64,64 + +Visibility: MissionSelector + +Categories: Campaign + +LockPreview: True + +Players: + PlayerReference@Neutral: + Name: Neutral + OwnsWorld: True + NonCombatant: True + Faction: vinylgod + PlayerReference@Player: + Name: Player + Playable: True + Required: True + AllowBots: False + LockFaction: True + Faction: vinylgod + LockSpawn: True + LockTeam: True + Enemies: Enemy + PlayerReference@Enemy: + Name: Enemy + Faction: stream + Bot: wax + Enemies: Player + +Actors: + spawn0: mpspawn + Owner: Neutral + Location: 10,54 + TheVan: popupvan + Owner: Player + Location: 10,54 + dig1: digger + Owner: Player + Location: 13,54 + dig2: digger + Owner: Player + Location: 12,56 + guard1: stacktank + Owner: Player + Location: 15,52 + guard2: spinner + Owner: Player + Location: 16,55 + guard3: djgrunt + Owner: Player + Location: 14,57 + guard4: djgrunt + Owner: Player + Location: 15,57 + TheAlgorithm: algorithm + Owner: Enemy + Location: 52,8 + ehub: streamhub + Owner: Enemy + Location: 48,10 + eproc1: transcoder + Owner: Enemy + Location: 44,8 + eproc2: transcoder + Owner: Enemy + Location: 55,14 + enode1: datacentre + Owner: Enemy + Location: 50,13 + enode2: datacentre + Owner: Enemy + Location: 54,11 + epods: podfarm + Owner: Enemy + Location: 45,13 + eprint: printfarm + Owner: Enemy + Location: 49,16 + eport: droneport + Owner: Enemy + Location: 56,18 + etur1: adblocker + Owner: Enemy + Location: 46,17 + etur2: adblocker + Owner: Enemy + Location: 52,18 + etur3: adblocker + Owner: Enemy + Location: 43,11 + escrap1: scraper + Owner: Enemy + Location: 47,20 + escrap2: scraper + Owner: Enemy + Location: 50,20 + emob1: drmwalker + Owner: Enemy + Location: 44,20 + emob2: drmwalker + Owner: Enemy + Location: 53,22 + emob3: bufferbot + Owner: Enemy + Location: 46,22 + emob4: bufferbot + Owner: Enemy + Location: 47,22 + emob5: bufferbot + Owner: Enemy + Location: 48,22 + mid1: adblocker + Owner: Enemy + Location: 34,28 + mid2: bufferbot + Owner: Enemy + Location: 33,30 + mid3: bufferbot + Owner: Enemy + Location: 35,30 + waxseed0: waxseed + Owner: Neutral + Location: 12,30 + waxseed1: waxseed + Owner: Neutral + Location: 14,50 + waxseed2: waxseed + Owner: Neutral + Location: 32,32 + waxseed3: waxseed + Owner: Neutral + Location: 50,14 + waxseed4: waxseed + Owner: Neutral + Location: 52,34 + +Rules: vinylgod|rules/campaign.yaml, rules.yaml + +FluentMessages: vinylgod|fluent/lua.ftl diff --git a/mods/vinylgod/maps/m03/rules.yaml b/mods/vinylgod/maps/m03/rules.yaml new file mode 100644 index 0000000..62b4d69 --- /dev/null +++ b/mods/vinylgod/maps/m03/rules.yaml @@ -0,0 +1,5 @@ +world: + LuaScript: + Scripts: campaign.lua, m03.lua + MissionData: + Briefing: The Algorithm has surfaced. It is sitting in the north-east behind everything it owns, scoring us.\n\nBuild a base. Build a Mastering Studio. Charge the orbital tonearm.\n\nThen put the needle through it.\n\nIt will hear the studio go up, and it will come for you. Let it. diff --git a/mods/vinylgod/maps/needledrop/map.bin b/mods/vinylgod/maps/needledrop/map.bin index 0e1d2ae..c2f1f4b 100644 Binary files a/mods/vinylgod/maps/needledrop/map.bin and b/mods/vinylgod/maps/needledrop/map.bin differ diff --git a/mods/vinylgod/maps/shellmap/map.bin b/mods/vinylgod/maps/shellmap/map.bin index e2688cb..0ed6a15 100644 Binary files a/mods/vinylgod/maps/shellmap/map.bin and b/mods/vinylgod/maps/shellmap/map.bin differ diff --git a/mods/vinylgod/maps/vinylgod/map.bin b/mods/vinylgod/maps/vinylgod/map.bin index d173fbc..927feb9 100644 Binary files a/mods/vinylgod/maps/vinylgod/map.bin and b/mods/vinylgod/maps/vinylgod/map.bin differ diff --git a/mods/vinylgod/missions/vinylgod.yaml b/mods/vinylgod/missions/vinylgod.yaml index 272b3d0..4fdaab4 100644 --- a/mods/vinylgod/missions/vinylgod.yaml +++ b/mods/vinylgod/missions/vinylgod.yaml @@ -1,3 +1,4 @@ SIDE A - Monster Robot Party: m01 m02 + m03 diff --git a/tools/gen_mission3.py b/tools/gen_mission3.py new file mode 100644 index 0000000..c908a96 --- /dev/null +++ b/tools/gen_mission3.py @@ -0,0 +1,124 @@ +#!/usr/bin/env python3 +"""Generate campaign mission 03 — THE DROP (finale: full base vs a live Stream base).""" +import os, struct +from PIL import Image + +SIZE = 64 +W = H = SIZE + 2 +MAP = os.path.join(os.path.dirname(__file__), '..', 'mods', 'vinylgod', 'maps', 'm03') +os.makedirs(MAP, exist_ok=True) + +WAX = [(14, 50, 6), (24, 40, 5), (32, 32, 6), (40, 24, 5), (50, 14, 6), (12, 30, 4), (52, 34, 4)] + +data = bytearray() +data += struct.pack('