[{"data":1,"prerenderedAt":215},["ShallowReactive",2],{"blog:phantom-1-5":3},[4,12,23,27,32,41,45,124,129,133,138,149,153,157,162,166,170,174,178,182,186,191,195,200,204,206],{"kind":5,"level":6,"id":7,"spans":8},"heading",2,"right-then",[9],{"kind":10,"text":11},"text","Right then",{"kind":13,"spans":14},"paragraph",[15,17,21],{"kind":10,"text":16},"1.5 is out. If Phantom's already open it'll update itself, and if it isn't, it's on the ",{"kind":18,"text":19,"href":20},"link","download page","\u002Fdownload",{"kind":10,"text":22}," where it always is.",{"kind":13,"spans":24},[25],{"kind":10,"text":26},"I'll be honest, this one got a bit out of hand. I sat down to tidy up the SDK and came back up for air with a new SDK, a code editor, and an Inspector that lets you pull the game apart with your bare hands. Sorry. Not that sorry.",{"kind":5,"level":6,"id":28,"spans":29},"the-sdk-take-two",[30],{"kind":10,"text":31},"The SDK, take two",{"kind":13,"spans":33},[34,36,39],{"kind":10,"text":35},"The old SDK did the job, but it was held together with string. So I binned it and started again. Everything lives under ",{"kind":37,"text":38},"code","phantom.aj",{"kind":10,"text":40}," now, and it gets at basically the whole game: rooms and whoever is in them, your animal and your stuff, dens, chat, buddies, trading, adventures, minigames, the art studio, even the game's own screens.",{"kind":13,"spans":42},[43],{"kind":10,"text":44},"Same SDK in a script as in a plugin, too. So when your little two line script inevitably turns into a plugin at 2am, you don't have to rewrite it.",{"kind":37,"text":46,"lang":47,"lines":48},"const room = await phantom.aj.room.current();\nconst players = await phantom.aj.room.players.all();\nconsole.log(room?.name, players.length, 'here');","ts",[49,78,96],[50,54,56,60,62,64,66,68,69,71,72,76],{"text":51,"light":52,"dark":53},"const","#5b6882","#8e9ab4",{"text":55}," room ",{"text":57,"light":58,"dark":59},"= ","#6c717b","#8a8a94",{"text":61,"light":52,"dark":53},"await",{"text":63}," phantom",{"text":65,"light":58,"dark":59},".",{"text":67},"aj",{"text":65,"light":58,"dark":59},{"text":70},"room",{"text":65,"light":58,"dark":59},{"text":73,"light":74,"dark":75},"current","#2160ad","#86b4f0",{"text":77,"light":58,"dark":59},"();",[79,80,82,83,84,85,86,87,88,89,90,92,93,95],{"text":51,"light":52,"dark":53},{"text":81}," players ",{"text":57,"light":58,"dark":59},{"text":61,"light":52,"dark":53},{"text":63},{"text":65,"light":58,"dark":59},{"text":67},{"text":65,"light":58,"dark":59},{"text":70},{"text":65,"light":58,"dark":59},{"text":91},"players",{"text":65,"light":58,"dark":59},{"text":94,"light":74,"dark":75},"all",{"text":77,"light":58,"dark":59},[97,99,100,102,104,105,107,109,111,113,114,116,118,122],{"text":98},"console",{"text":65,"light":58,"dark":59},{"text":101,"light":74,"dark":75},"log",{"text":103,"light":58,"dark":59},"(",{"text":70},{"text":106,"light":58,"dark":59},"?.",{"text":108},"name",{"text":110,"light":58,"dark":59},",",{"text":112}," players",{"text":65,"light":58,"dark":59},{"text":115},"length",{"text":117,"light":58,"dark":59},", ",{"text":119,"light":120,"dark":121},"'here'","#1c7a4f","#8fcfa6",{"text":123,"light":58,"dark":59},");",{"kind":5,"level":6,"id":125,"spans":126},"scripts-grew-up",[127],{"kind":10,"text":128},"Scripts grew up",{"kind":13,"spans":130},[131],{"kind":10,"text":132},"Scripts used to be a box you typed into and hoped for the best. It's a proper editor now.",{"kind":134,"src":135,"alt":136,"caption":137},"image","\u002Fblog\u002Fphantom-1-5\u002Fscripts.jpg","The Scripts editor with folders on the left, two scripts side by side and the console below","Two scripts side by side, and an object opened up in the console",{"kind":13,"spans":139},[140,142,143,145,147],{"kind":10,"text":141},"You get folders, tabs, and two scripts side by side if you're feeling fancy. It suggests things as you type, with the SDK's own docs right there, so you can stop guessing what a function's called. Ctrl click a name and it takes you to where it's defined. It'll rename things for you, and when you inevitably spell ",{"kind":37,"text":94},{"kind":10,"text":144}," as ",{"kind":37,"text":146},"al1",{"kind":10,"text":148}," it offers to fix it rather than just sitting there judging you.",{"kind":13,"spans":150},[151],{"kind":10,"text":152},"There's find and replace across all your scripts, a history of every run with what it gave back, and you can pick which game a script runs on. Ctrl P jumps to a script, Ctrl Shift P does everything else. If you've used VS Code you'll feel right at home. If you haven't, you're about to learn some very useful shortcuts.",{"kind":134,"src":154,"alt":155,"caption":156},"\u002Fblog\u002Fphantom-1-5\u002Fsuggestions.jpg","A list of suggestions with the SDK's docs beside it","Suggestions as you type, docs included",{"kind":5,"level":6,"id":158,"spans":159},"the-inspector-now-with-a-screwdriver",[160],{"kind":10,"text":161},"The Inspector, now with a screwdriver",{"kind":13,"spans":163},[164],{"kind":10,"text":165},"The Inspector used to let you look. Now it lets you touch, which is either brilliant or a terrible idea depending on what you do with it.",{"kind":134,"src":167,"alt":168,"caption":169},"\u002Fblog\u002Fphantom-1-5\u002Finspector-display.jpg","The Inspector's Display tab, with an avatar's colour and filters open","Tint your animal purple. Give it a glow. Live your truth.",{"kind":13,"spans":171},[172],{"kind":10,"text":173},"Open up any value, however far down it's buried, and change it while the game's running. Numbers drag, switches flip, colours get a proper picker. The new Display tab lets you tint things, slap a glow or a blur on them, or pause a movie clip mid frame and scrub through it like you're reviewing VAR footage. You can drag things round the stage, shove them into other containers, or just make them disappear.",{"kind":13,"spans":175},[176],{"kind":10,"text":177},"If you want to get properly stuck in, you can call the game's own methods, or hook them and watch every call go past. Change what goes in, change what comes out, or stop it running altogether. There's a browser for every class the game has loaded, and you can keep an eye on any value as it changes.",{"kind":134,"src":179,"alt":180,"caption":181},"\u002Fblog\u002Fphantom-1-5\u002Finspector-hook.jpg","Hooking a method in the Inspector","A hook on an emote, counting every call",{"kind":13,"spans":183},[184],{"kind":10,"text":185},"And before you panic: every change can be undone. Ctrl Z takes back the last one, and Reset puts something back exactly how the game had it. It all stays on your screen too. Nothing you fiddle with in the Inspector goes anywhere near Animal Jam's servers unless you call something that sends it.",{"kind":5,"level":6,"id":187,"spans":188},"phantom-hd",[189],{"kind":10,"text":190},"Phantom HD",{"kind":13,"spans":192},[193],{"kind":10,"text":194},"Turns out Animal Jam has been drawing itself a bit blurrier than it needs to, all these years. Phantom HD sorts that out. The game draws at its best quality and the animals get smoothed, so they stop looking like they've been cut out with safety scissors. There's a smooth camera as well, which glides after you round the room instead of lurching about. Both live in Settings under Graphics, and you can flick them on while you're playing.",{"kind":5,"level":6,"id":196,"spans":197},"bits-and-bobs",[198],{"kind":10,"text":199},"Bits and bobs",{"kind":13,"spans":201},[202],{"kind":10,"text":203},"Packets has had a makeover, and each game's tile now shows your animal instead of a letter. The accounts screen, the command palette and the light theme have all been redone, and pages finally use the whole window instead of huddling in the middle. Plugin pages show the plugin's README now. Linux folk can resize the window from its edges, which frankly should have worked from day one. And times after midnight say 00 instead of 24, because apparently I can't tell the time.",{"kind":205},"rule",{"kind":13,"spans":207},[208,210,213],{"kind":10,"text":209},"That's your lot. Go break something, then come and tell me about it in the ",{"kind":18,"text":211,"href":212},"Discord","https:\u002F\u002Fdiscord.gg\u002Frvu5wjuxvt",{"kind":10,"text":214},". Cheers.",1793064271157]