diff options
| author | Caleb <caleb.mabry.15@cnu.edu> | 2022-09-08 00:51:31 -0400 |
|---|---|---|
| committer | Caleb <caleb.mabry.15@cnu.edu> | 2022-09-08 00:51:31 -0400 |
| commit | d99a619e26f38c729d74d8dc585e8ce13236ffb7 (patch) | |
| tree | ec3bb6183eaeed3fe92440b76447b3bb71bc16dc /webAO/dom/changeRoleOOC.ts | |
| parent | 84cdbfff31c31eff9e7ba2a1d6c73f6d08ac5e43 (diff) | |
Removed all window functions from client
Diffstat (limited to 'webAO/dom/changeRoleOOC.ts')
| -rw-r--r-- | webAO/dom/changeRoleOOC.ts | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/webAO/dom/changeRoleOOC.ts b/webAO/dom/changeRoleOOC.ts new file mode 100644 index 0000000..d838cb3 --- /dev/null +++ b/webAO/dom/changeRoleOOC.ts @@ -0,0 +1,13 @@ +import { updateActionCommands } from './updateActionCommands' +import { client } from '../client' +/** + * Change role via OOC. + */ +export function changeRoleOOC() { + const roleselect = <HTMLInputElement>document.getElementById("role_select"); + + client.sendOOC(`/pos ${roleselect.value}`); + client.sendServer(`SP#${roleselect.value}#%`); + updateActionCommands(roleselect.value); +} +window.changeRoleOOC = changeRoleOOC;
\ No newline at end of file |
