Anybody know how I can perform the command to select the commander? I am working on a UI Mod that will select the commander and hopefully center the camera above it. Thanks ahead of time for any help. Javascript code: $(function() { $('body').append('<div id="locate_commander"><p>Select Commander</p></div>'); var element = $('#locate_commander'); element.click(selectCommander); function selectCommander() { element.html("Clicked"); engine.call("holodeck.setCommanderId", msg.data.client.commander.id); } });
I think the Commander HUD mod includes that? Look at the select commander keybinding, or Autoselect Commander mod. Generally, api.select.commander and api.camera.track. This selects all commanders in a team army game. Judging from your code you've been looking at PTE, which I haven't really tested in that scenario.
Thanks. That is helpful. I was thinking about adding a button above the ping button to select the commander. Any tips for that?
But this is the modding forum! Here we make simple things complicated just for fun. This is what inputmap.js does when you press 'b' Code: 'select commander': input.doubleTap(api.select.commander, function () { api.camera.track(true); input.doubleTap.reset(); }),