mirror of
https://github.com/SPLURT-Station/S.P.L.U.R.T-Station-13.git
synced 2025-12-10 09:54:52 +00:00
cogchamp changes. syncing then building tgui next
This commit is contained in:
@@ -46,10 +46,11 @@ export const ClockworkSlab = (props, context) => {
|
|||||||
title="Recollection"
|
title="Recollection"
|
||||||
buttons={(
|
buttons={(
|
||||||
<Button
|
<Button
|
||||||
content="Recital"
|
|
||||||
icon="cog"
|
icon="cog"
|
||||||
tooltipPosition={"left"}
|
tooltipPosition={"left"}
|
||||||
onClick={() => act('toggle')} />
|
onClick={() => act('toggle')}>
|
||||||
|
Recital
|
||||||
|
</Button>
|
||||||
)}>
|
)}>
|
||||||
<Box>
|
<Box>
|
||||||
{HONOR_RATVAR ? (
|
{HONOR_RATVAR ? (
|
||||||
@@ -96,12 +97,13 @@ export const ClockworkSlab = (props, context) => {
|
|||||||
<Fragment key={cat.name}>
|
<Fragment key={cat.name}>
|
||||||
<br />
|
<br />
|
||||||
<Button
|
<Button
|
||||||
content={cat.name}
|
|
||||||
tooltip={cat.desc}
|
tooltip={cat.desc}
|
||||||
tooltipPosition={'right'}
|
tooltipPosition={'right'}
|
||||||
onClick={() => act('rec_category', {
|
onClick={() => act('rec_category', {
|
||||||
"category": cat.name,
|
"category": cat.name,
|
||||||
})} />
|
})} >
|
||||||
|
{cat.name}
|
||||||
|
</Button>
|
||||||
</Fragment>
|
</Fragment>
|
||||||
))}
|
))}
|
||||||
<Divider />
|
<Divider />
|
||||||
@@ -156,11 +158,12 @@ export const ClockworkSlab = (props, context) => {
|
|||||||
title="Power"
|
title="Power"
|
||||||
buttons={(
|
buttons={(
|
||||||
<Button
|
<Button
|
||||||
content="Recollection"
|
|
||||||
icon="book"
|
icon="book"
|
||||||
tooltip={"Tutorial"}
|
tooltip={"Tutorial"}
|
||||||
tooltipPosition={"left"}
|
tooltipPosition={"left"}
|
||||||
onClick={() => act('toggle')} />
|
onClick={() => act('toggle')}>
|
||||||
|
Recollection
|
||||||
|
</Button>
|
||||||
)}>
|
)}>
|
||||||
<b>{power}</b> power is available for scripture
|
<b>{power}</b> power is available for scripture
|
||||||
and other consumers.
|
and other consumers.
|
||||||
@@ -232,7 +235,6 @@ export const ClockworkSlab = (props, context) => {
|
|||||||
collapsing
|
collapsing
|
||||||
textAlign="right">
|
textAlign="right">
|
||||||
<Button
|
<Button
|
||||||
content={`Recite ${script.required}`}
|
|
||||||
disabled={
|
disabled={
|
||||||
script.required_unformatted >= power_unformatted
|
script.required_unformatted >= power_unformatted
|
||||||
}
|
}
|
||||||
@@ -240,22 +242,25 @@ export const ClockworkSlab = (props, context) => {
|
|||||||
tooltipPosition={'left'}
|
tooltipPosition={'left'}
|
||||||
onClick={() => act('recite', {
|
onClick={() => act('recite', {
|
||||||
'script': script.type,
|
'script': script.type,
|
||||||
})} />
|
})} >
|
||||||
|
{`Recite ${script.required}`}
|
||||||
|
</Button>
|
||||||
</Table.Cell>
|
</Table.Cell>
|
||||||
<Table.Cell
|
<Table.Cell
|
||||||
collapsing
|
collapsing
|
||||||
textAlign="center">
|
textAlign="center">
|
||||||
<Button
|
<Button
|
||||||
fluid
|
fluid
|
||||||
|
disabled={!script.quickbind}
|
||||||
|
onClick={() => act('bind', {
|
||||||
|
'script': script.type,
|
||||||
|
})}>
|
||||||
content={script.bound ? (
|
content={script.bound ? (
|
||||||
`Unbind ${script.bound}`
|
`Unbind ${script.bound}`
|
||||||
) : (
|
) : (
|
||||||
'Quickbind'
|
'Quickbind'
|
||||||
)}
|
)}
|
||||||
disabled={!script.quickbind}
|
</Button>
|
||||||
onClick={() => act('bind', {
|
|
||||||
'script': script.type,
|
|
||||||
})} />
|
|
||||||
</Table.Cell>
|
</Table.Cell>
|
||||||
</Table.Row>
|
</Table.Row>
|
||||||
))}
|
))}
|
||||||
|
|||||||
@@ -45,11 +45,11 @@ export const TelecommsInteraction = (props, context) => {
|
|||||||
<LabeledList>
|
<LabeledList>
|
||||||
<LabeledList.Item label="Power Status">
|
<LabeledList.Item label="Power Status">
|
||||||
<Button
|
<Button
|
||||||
content={power ? 'On' : 'Off'}
|
|
||||||
icon={power ? 'power-off' : 'times'}
|
icon={power ? 'power-off' : 'times'}
|
||||||
color={power ? 'good' : 'bad'}
|
color={power ? 'good' : 'bad'}
|
||||||
onClick={() => act('toggle')}
|
onClick={() => act('toggle')}>
|
||||||
/>
|
{power ? 'On' : 'Off'}
|
||||||
|
</Button>
|
||||||
</LabeledList.Item>
|
</LabeledList.Item>
|
||||||
{power ? (
|
{power ? (
|
||||||
<Fragment>
|
<Fragment>
|
||||||
@@ -80,40 +80,40 @@ export const TelecommsInteraction = (props, context) => {
|
|||||||
<Fragment>
|
<Fragment>
|
||||||
<LabeledList.Item label="Broadcasting">
|
<LabeledList.Item label="Broadcasting">
|
||||||
<Button
|
<Button
|
||||||
content={machine.broadcast ? 'YES' : 'NO'}
|
|
||||||
icon={machine.broadcast ? 'check' : 'times'}
|
icon={machine.broadcast ? 'check' : 'times'}
|
||||||
color={machine.broadcast ? 'good' : 'bad'}
|
color={machine.broadcast ? 'good' : 'bad'}
|
||||||
onClick={() => act('relay', {
|
onClick={() => act('relay', {
|
||||||
'broadcast': true,
|
'broadcast': true,
|
||||||
})}
|
})}>
|
||||||
/>
|
{machine.broadcast ? 'YES' : 'NO'}
|
||||||
|
</Button>
|
||||||
</LabeledList.Item>
|
</LabeledList.Item>
|
||||||
<LabeledList.Item label="Receiving">
|
<LabeledList.Item label="Receiving">
|
||||||
<Button
|
<Button
|
||||||
content={machine.receiving ? 'YES' : 'NO'}
|
|
||||||
icon={machine.receiving ? 'check' : 'times'}
|
icon={machine.receiving ? 'check' : 'times'}
|
||||||
color={machine.receiving ? 'good' : 'bad'}
|
color={machine.receiving ? 'good' : 'bad'}
|
||||||
onClick={() => act('relay', {
|
onClick={() => act('relay', {
|
||||||
'receiving': true,
|
'receiving': true,
|
||||||
})}
|
})}>
|
||||||
/>
|
{machine.receiving ? 'YES' : 'NO'}
|
||||||
|
</Button>
|
||||||
</LabeledList.Item>
|
</LabeledList.Item>
|
||||||
</Fragment>
|
</Fragment>
|
||||||
)}
|
)}
|
||||||
{!!isbus && (
|
{!!isbus && (
|
||||||
<LabeledList.Item label="Change Signal Frequency">
|
<LabeledList.Item label="Change Signal Frequency">
|
||||||
<Button
|
<Button
|
||||||
content={machine.chang_frequency ? (
|
|
||||||
'Enabled'
|
|
||||||
) : (
|
|
||||||
'Disabled'
|
|
||||||
)}
|
|
||||||
icon={machine.chang_frequency ? 'power-off' : 'times'}
|
icon={machine.chang_frequency ? 'power-off' : 'times'}
|
||||||
color={machine.chang_frequency ? 'good' : 'bad'}
|
color={machine.chang_frequency ? 'good' : 'bad'}
|
||||||
onClick={() => act('frequency', {
|
onClick={() => act('frequency', {
|
||||||
'toggle': true,
|
'toggle': true,
|
||||||
})}
|
})}>
|
||||||
/>
|
{machine.chang_frequency ? (
|
||||||
|
'Enabled'
|
||||||
|
) : (
|
||||||
|
'Disabled'
|
||||||
|
)}
|
||||||
|
</Button>
|
||||||
{!!machine.chang_frequency && (
|
{!!machine.chang_frequency && (
|
||||||
<NumberInput
|
<NumberInput
|
||||||
animate
|
animate
|
||||||
@@ -141,25 +141,25 @@ export const TelecommsInteraction = (props, context) => {
|
|||||||
buttons={multitool_buf ? (
|
buttons={multitool_buf ? (
|
||||||
<Fragment>
|
<Fragment>
|
||||||
<Button
|
<Button
|
||||||
content="Link"
|
|
||||||
onClick={() => act('multitool', {
|
onClick={() => act('multitool', {
|
||||||
'Link': true,
|
'Link': true,
|
||||||
})}
|
})}>
|
||||||
/>
|
Link
|
||||||
|
</Button>
|
||||||
<Button
|
<Button
|
||||||
content="Flush"
|
|
||||||
onClick={() => act('multitool', {
|
onClick={() => act('multitool', {
|
||||||
'Flush': true,
|
'Flush': true,
|
||||||
})}
|
})}>
|
||||||
/>
|
Flush
|
||||||
|
</Button>
|
||||||
</Fragment>
|
</Fragment>
|
||||||
) : (
|
) : (
|
||||||
<Button
|
<Button
|
||||||
content="Add Machine"
|
|
||||||
onClick={() => act('multitool', {
|
onClick={() => act('multitool', {
|
||||||
'Add': true,
|
'Add': true,
|
||||||
})}
|
})}>
|
||||||
/>
|
Add Machine
|
||||||
|
</Button>
|
||||||
)}>
|
)}>
|
||||||
{!!multitool_buf && (
|
{!!multitool_buf && (
|
||||||
`${multitool_buf.name} (${multitool_buf.id})`
|
`${multitool_buf.name} (${multitool_buf.id})`
|
||||||
@@ -183,11 +183,11 @@ export const TelecommsInteraction = (props, context) => {
|
|||||||
label={entity.ref}
|
label={entity.ref}
|
||||||
buttons={(
|
buttons={(
|
||||||
<Button
|
<Button
|
||||||
content="Remove"
|
|
||||||
onClick={() => act('unlink', {
|
onClick={() => act('unlink', {
|
||||||
'value': entity.ref,
|
'value': entity.ref,
|
||||||
})}
|
})}>
|
||||||
/>
|
Remove
|
||||||
|
</Button>
|
||||||
)}>
|
)}>
|
||||||
{`${entity.name} (${entity.id})`}
|
{`${entity.name} (${entity.id})`}
|
||||||
</LabeledList.Item>
|
</LabeledList.Item>
|
||||||
@@ -198,11 +198,11 @@ export const TelecommsInteraction = (props, context) => {
|
|||||||
title="Filtering Frequencies"
|
title="Filtering Frequencies"
|
||||||
level={2}>
|
level={2}>
|
||||||
<Button
|
<Button
|
||||||
content="Add Filter"
|
|
||||||
onClick={() => act('freq', {
|
onClick={() => act('freq', {
|
||||||
'add': true,
|
'add': true,
|
||||||
})}
|
})}>
|
||||||
/>
|
Add Filter
|
||||||
|
</Button>
|
||||||
<br />
|
<br />
|
||||||
<br />
|
<br />
|
||||||
{(freq_listening && freq_listening.length) ? (
|
{(freq_listening && freq_listening.length) ? (
|
||||||
@@ -213,17 +213,17 @@ export const TelecommsInteraction = (props, context) => {
|
|||||||
<Button
|
<Button
|
||||||
key={thing}
|
key={thing}
|
||||||
icon="times"
|
icon="times"
|
||||||
content={valid ? (
|
onClick={() => act('freq', {
|
||||||
|
'remove': thing,
|
||||||
|
})}>
|
||||||
|
{valid ? (
|
||||||
<span style={`color: ${valid.color}`}>
|
<span style={`color: ${valid.color}`}>
|
||||||
{`${thing} (${valid.name})`}
|
{`${thing} (${valid.name})`}
|
||||||
</span>
|
</span>
|
||||||
) : (
|
) : (
|
||||||
thing
|
thing
|
||||||
)}
|
)}
|
||||||
onClick={() => act('freq', {
|
</Button>
|
||||||
'remove': thing,
|
|
||||||
})}
|
|
||||||
/>
|
|
||||||
);
|
);
|
||||||
})
|
})
|
||||||
) : (
|
) : (
|
||||||
|
|||||||
@@ -50,15 +50,17 @@ export const TelecommsLogBrowser = (props, context) => {
|
|||||||
buttons={(
|
buttons={(
|
||||||
<Fragment>
|
<Fragment>
|
||||||
<Button
|
<Button
|
||||||
content="Flush Buffer"
|
|
||||||
icon="minus-circle"
|
icon="minus-circle"
|
||||||
disabled={!servers.length || !!selected}
|
disabled={!servers.length || !!selected}
|
||||||
onClick={() => act('release')} />
|
onClick={() => act('release')}>
|
||||||
|
Flush Buffer
|
||||||
|
</Button>
|
||||||
<Button
|
<Button
|
||||||
content="Probe Network"
|
|
||||||
icon="sync"
|
icon="sync"
|
||||||
disabled={selected}
|
disabled={selected}
|
||||||
onClick={() => act('probe')} />
|
onClick={() => act('probe')}>
|
||||||
|
Probe Network
|
||||||
|
</Button>
|
||||||
</Fragment>
|
</Fragment>
|
||||||
)}>
|
)}>
|
||||||
{servers ? (
|
{servers ? (
|
||||||
@@ -71,10 +73,10 @@ export const TelecommsLogBrowser = (props, context) => {
|
|||||||
label="Selected Server"
|
label="Selected Server"
|
||||||
buttons={(
|
buttons={(
|
||||||
<Button
|
<Button
|
||||||
content="Disconnect"
|
|
||||||
disabled={!selected}
|
disabled={!selected}
|
||||||
onClick={() => act('mainmenu')}
|
onClick={() => act('mainmenu')}>
|
||||||
/>
|
Disconnect
|
||||||
|
</Button>
|
||||||
)}>
|
)}>
|
||||||
{selected ? (
|
{selected ? (
|
||||||
`${selected.name} (${selected.id})`
|
`${selected.name} (${selected.id})`
|
||||||
@@ -131,10 +133,11 @@ export const TelecommsLogBrowser = (props, context) => {
|
|||||||
label="Filename"
|
label="Filename"
|
||||||
buttons={(
|
buttons={(
|
||||||
<Button
|
<Button
|
||||||
content="Delete"
|
|
||||||
onClick={() => act('delete', {
|
onClick={() => act('delete', {
|
||||||
'value': logs.ref,
|
'value': logs.ref,
|
||||||
})} />
|
})}>
|
||||||
|
Delete
|
||||||
|
</Button>
|
||||||
)}>
|
)}>
|
||||||
{logs.name}
|
{logs.name}
|
||||||
</LabeledList.Item>
|
</LabeledList.Item>
|
||||||
@@ -172,12 +175,13 @@ export const TelecommsLogBrowser = (props, context) => {
|
|||||||
label={`${server.ref}`}
|
label={`${server.ref}`}
|
||||||
buttons={(
|
buttons={(
|
||||||
<Button
|
<Button
|
||||||
content="Connect"
|
|
||||||
selected={data.selected
|
selected={data.selected
|
||||||
&& (server.ref === data.selected.ref)}
|
&& (server.ref === data.selected.ref)}
|
||||||
onClick={() => act('viewmachine', {
|
onClick={() => act('viewmachine', {
|
||||||
'value': server.id,
|
'value': server.id,
|
||||||
})} />
|
})}>
|
||||||
|
Connect
|
||||||
|
</Button>
|
||||||
)}>
|
)}>
|
||||||
{`${server.name} (${server.id})`}
|
{`${server.name} (${server.id})`}
|
||||||
</LabeledList.Item>
|
</LabeledList.Item>
|
||||||
|
|||||||
@@ -54,15 +54,17 @@ export const TelecommsMonitor = (props, context) => {
|
|||||||
buttons={(
|
buttons={(
|
||||||
<Fragment>
|
<Fragment>
|
||||||
<Button
|
<Button
|
||||||
content="Flush Buffer"
|
|
||||||
icon="minus-circle"
|
icon="minus-circle"
|
||||||
disabled={!servers.length || !!selected}
|
disabled={!servers.length || !!selected}
|
||||||
onClick={() => act('release')} />
|
onClick={() => act('release')}>
|
||||||
|
Flush Buffer
|
||||||
|
</Button>
|
||||||
<Button
|
<Button
|
||||||
content="Probe Network"
|
|
||||||
icon="sync"
|
icon="sync"
|
||||||
disabled={selected}
|
disabled={selected}
|
||||||
onClick={() => act('probe')} />
|
onClick={() => act('probe')}>
|
||||||
|
Probe Network
|
||||||
|
</Button>
|
||||||
</Fragment>
|
</Fragment>
|
||||||
)}>
|
)}>
|
||||||
{!selected ? (
|
{!selected ? (
|
||||||
|
|||||||
@@ -95,15 +95,17 @@ export const TelecommsPDALog = (props, context) => {
|
|||||||
buttons={(
|
buttons={(
|
||||||
<Fragment>
|
<Fragment>
|
||||||
<Button
|
<Button
|
||||||
content="Flush Buffer"
|
|
||||||
icon="minus-circle"
|
icon="minus-circle"
|
||||||
disabled={!servers.length}
|
disabled={!servers.length}
|
||||||
onClick={() => act('release')} />
|
onClick={() => act('release')}>
|
||||||
|
Flush Buffer
|
||||||
|
</Button>
|
||||||
<Button
|
<Button
|
||||||
content="Probe Network"
|
|
||||||
icon="sync"
|
icon="sync"
|
||||||
disabled={servers.length}
|
disabled={servers.length}
|
||||||
onClick={() => act('probe')} />
|
onClick={() => act('probe')}>
|
||||||
|
Probe Network
|
||||||
|
</Button>
|
||||||
</Fragment>
|
</Fragment>
|
||||||
)}>
|
)}>
|
||||||
{servers ? (
|
{servers ? (
|
||||||
@@ -118,17 +120,17 @@ export const TelecommsPDALog = (props, context) => {
|
|||||||
buttons={(
|
buttons={(
|
||||||
<Fragment>
|
<Fragment>
|
||||||
<Button
|
<Button
|
||||||
content="Change Password"
|
|
||||||
disabled={!authenticated || !selected}
|
disabled={!authenticated || !selected}
|
||||||
onClick={() => act('change_auth')}
|
onClick={() => act('change_auth')}>
|
||||||
/>
|
Change Password
|
||||||
{canhack && (
|
</Button>
|
||||||
|
{!!canhack && (
|
||||||
<Button
|
<Button
|
||||||
content="Brute Force"
|
|
||||||
color="bad"
|
color="bad"
|
||||||
disabled={authenticated || !selected}
|
disabled={authenticated || !selected}
|
||||||
onClick={() => act('hack')}
|
onClick={() => act('hack')}>
|
||||||
/>
|
Brute Force
|
||||||
|
</Button>
|
||||||
)}
|
)}
|
||||||
</Fragment>
|
</Fragment>
|
||||||
)}>
|
)}>
|
||||||
@@ -139,18 +141,18 @@ export const TelecommsPDALog = (props, context) => {
|
|||||||
buttons={(
|
buttons={(
|
||||||
<Fragment>
|
<Fragment>
|
||||||
<Button
|
<Button
|
||||||
content={!authenticated ? 'Login' : 'Logout'}
|
|
||||||
icon={authenticated ? 'unlock' : 'lock'}
|
icon={authenticated ? 'unlock' : 'lock'}
|
||||||
color={authenticated ? 'good' : 'bad'}
|
color={authenticated ? 'good' : 'bad'}
|
||||||
disabled={!selected}
|
disabled={!selected}
|
||||||
onClick={() => act('auth')}
|
onClick={() => act('auth')}>
|
||||||
/>
|
{!authenticated ? 'Login' : 'Logout'}
|
||||||
|
</Button>
|
||||||
<Button
|
<Button
|
||||||
content="Disconnect"
|
|
||||||
icon="minus-circle"
|
icon="minus-circle"
|
||||||
disabled={!selected}
|
disabled={!selected}
|
||||||
onClick={() => act('mainmenu')}
|
onClick={() => act('mainmenu')}>
|
||||||
/>
|
Disconnect
|
||||||
|
</Button>
|
||||||
</Fragment>
|
</Fragment>
|
||||||
)}>
|
)}>
|
||||||
{selected ? (
|
{selected ? (
|
||||||
@@ -214,12 +216,13 @@ export const TelecommsPDALog = (props, context) => {
|
|||||||
label={`${server.ref}`}
|
label={`${server.ref}`}
|
||||||
buttons={(
|
buttons={(
|
||||||
<Button
|
<Button
|
||||||
content="Connect"
|
|
||||||
selected={data.selected
|
selected={data.selected
|
||||||
&& (server.ref === data.selected.ref)}
|
&& (server.ref === data.selected.ref)}
|
||||||
onClick={() => act('viewmachine', {
|
onClick={() => act('viewmachine', {
|
||||||
'value': server.id,
|
'value': server.id,
|
||||||
})} />
|
})}>
|
||||||
|
Connect
|
||||||
|
</Button>
|
||||||
)}>
|
)}>
|
||||||
{`${server.name} (${server.id})`}
|
{`${server.name} (${server.id})`}
|
||||||
</LabeledList.Item>
|
</LabeledList.Item>
|
||||||
@@ -267,18 +270,18 @@ export const TeleLogs = (props, context) => {
|
|||||||
return (
|
return (
|
||||||
<Section title="Logs">
|
<Section title="Logs">
|
||||||
<Button
|
<Button
|
||||||
content="Refresh"
|
|
||||||
icon="sync"
|
icon="sync"
|
||||||
onClick={() => act('refresh')}
|
onClick={() => act('refresh')}>
|
||||||
/>
|
Refresh
|
||||||
|
</Button>
|
||||||
<Button.Confirm
|
<Button.Confirm
|
||||||
content="Delete All Logs"
|
|
||||||
icon="trash"
|
icon="trash"
|
||||||
disabled={!log_to_use || !(log_to_use && log_to_use.length)}
|
disabled={!log_to_use || !(log_to_use && log_to_use.length)}
|
||||||
onClick={() => act('clear_log', {
|
onClick={() => act('clear_log', {
|
||||||
'value': msgs_log ? 'rc_msgs' : 'pda_logs',
|
'value': msgs_log ? 'rc_msgs' : 'pda_logs',
|
||||||
})}
|
})}>
|
||||||
/>
|
Delete All Logs
|
||||||
|
</Button.Confirm>
|
||||||
<Section
|
<Section
|
||||||
title="Messages"
|
title="Messages"
|
||||||
level={2}>
|
level={2}>
|
||||||
@@ -289,11 +292,11 @@ export const TeleLogs = (props, context) => {
|
|||||||
label={msgs_log ? "Sending Dep." : "Sender"}
|
label={msgs_log ? "Sending Dep." : "Sender"}
|
||||||
buttons={(
|
buttons={(
|
||||||
<Button
|
<Button
|
||||||
content="Delete"
|
|
||||||
onClick={() => act('del_log', {
|
onClick={() => act('del_log', {
|
||||||
'ref': message.ref,
|
'ref': message.ref,
|
||||||
})}
|
})}>
|
||||||
/>
|
Delete
|
||||||
|
</Button>
|
||||||
)}>
|
)}>
|
||||||
{message.sender}
|
{message.sender}
|
||||||
</LabeledList.Item>
|
</LabeledList.Item>
|
||||||
@@ -305,14 +308,14 @@ export const TeleLogs = (props, context) => {
|
|||||||
label="Message"
|
label="Message"
|
||||||
buttons={(
|
buttons={(
|
||||||
!!message.picture && ( // don't send img over req
|
!!message.picture && ( // don't send img over req
|
||||||
<Button // Had to use _act for this.
|
<Button
|
||||||
content="Image"
|
|
||||||
icon="image"
|
icon="image"
|
||||||
onClick={() => Byond.topic({
|
onClick={() => Byond.topic({
|
||||||
'src': message.ref,
|
'src': message.ref,
|
||||||
'photo': 1,
|
'photo': 1,
|
||||||
})}
|
})}>
|
||||||
/>
|
Image
|
||||||
|
</Button>
|
||||||
)
|
)
|
||||||
)}>
|
)}>
|
||||||
{message.message}
|
{message.message}
|
||||||
@@ -362,7 +365,7 @@ export const TeleLogs = (props, context) => {
|
|||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
export const CustomMsg = (props, context) => {
|
export const CustomMsg = context => {
|
||||||
const { act, data } = useBackend(context);
|
const { act, data } = useBackend(context);
|
||||||
const fake_message = data.fake_message || {
|
const fake_message = data.fake_message || {
|
||||||
'sender': 'System Administrator',
|
'sender': 'System Administrator',
|
||||||
@@ -373,19 +376,19 @@ export const CustomMsg = (props, context) => {
|
|||||||
return (
|
return (
|
||||||
<Section title="Custom Message">
|
<Section title="Custom Message">
|
||||||
<Button
|
<Button
|
||||||
content="Reset"
|
|
||||||
icon="sync"
|
icon="sync"
|
||||||
onClick={() => act('fake', {
|
onClick={() => act('fake', {
|
||||||
'reset': true,
|
'reset': true,
|
||||||
})}
|
})}>
|
||||||
/>
|
Reset
|
||||||
|
</Button>
|
||||||
<Button
|
<Button
|
||||||
content="Send"
|
|
||||||
disabled={!fake_message.recepient || !fake_message.message}
|
disabled={!fake_message.recepient || !fake_message.message}
|
||||||
onClick={() => act('fake', {
|
onClick={() => act('fake', {
|
||||||
'send': true,
|
'send': true,
|
||||||
})}
|
})}>
|
||||||
/>
|
Send
|
||||||
|
</Button>
|
||||||
<br /><br />
|
<br /><br />
|
||||||
<LabeledList>
|
<LabeledList>
|
||||||
<LabeledList.Item label="Sender">
|
<LabeledList.Item label="Sender">
|
||||||
@@ -410,16 +413,16 @@ export const CustomMsg = (props, context) => {
|
|||||||
</LabeledList.Item>
|
</LabeledList.Item>
|
||||||
<LabeledList.Item label="Recipient">
|
<LabeledList.Item label="Recipient">
|
||||||
<Button
|
<Button
|
||||||
content={fake_message.recepient ? (
|
selected={fake_message.recepient}
|
||||||
|
onClick={() => act('fake', {
|
||||||
|
'recepient': true,
|
||||||
|
})}>
|
||||||
|
{fake_message.recepient ? (
|
||||||
fake_message.recepient
|
fake_message.recepient
|
||||||
) : (
|
) : (
|
||||||
'Select'
|
'Select'
|
||||||
)}
|
)}
|
||||||
selected={fake_message.recepient}
|
</Button>
|
||||||
onClick={() => act('fake', {
|
|
||||||
'recepient': true,
|
|
||||||
})}
|
|
||||||
/>
|
|
||||||
</LabeledList.Item>
|
</LabeledList.Item>
|
||||||
<LabeledList.Item label="Message">
|
<LabeledList.Item label="Message">
|
||||||
<Input
|
<Input
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ export const VrSleeper = (props, context) => {
|
|||||||
)}
|
)}
|
||||||
|
|
||||||
<Section title={"Virtual Avatar"}>
|
<Section title={"Virtual Avatar"}>
|
||||||
{!!data.vr_avatar && (
|
{data.vr_avatar ? (
|
||||||
<LabeledList>
|
<LabeledList>
|
||||||
<LabeledList.Item
|
<LabeledList.Item
|
||||||
label={"Name"} >
|
label={"Name"} >
|
||||||
@@ -41,39 +41,42 @@ export const VrSleeper = (props, context) => {
|
|||||||
</LabeledList.Item>
|
</LabeledList.Item>
|
||||||
)}
|
)}
|
||||||
</LabeledList>
|
</LabeledList>
|
||||||
) || (
|
) : (
|
||||||
"No Virtual Avatar detected"
|
"No Virtual Avatar detected"
|
||||||
)}
|
)}
|
||||||
</Section>
|
</Section>
|
||||||
|
|
||||||
<Section title="VR Commands">
|
<Section title="VR Commands">
|
||||||
<Button
|
<Button
|
||||||
content={data.toggle_open
|
|
||||||
? 'Close VR Sleeper'
|
|
||||||
: 'Open VR Sleeper'}
|
|
||||||
icon={data.toggle_open ? 'unlock' : 'lock'}
|
icon={data.toggle_open ? 'unlock' : 'lock'}
|
||||||
disabled={data.stored < data.max}
|
disabled={data.stored < data.max}
|
||||||
onClick={() => act('toggle_open')} />
|
onClick={() => act('toggle_open')}>
|
||||||
|
{data.toggle_open
|
||||||
|
? 'Close VR Sleeper'
|
||||||
|
: 'Open VR Sleeper'}
|
||||||
|
</Button>
|
||||||
<Section>
|
<Section>
|
||||||
{!!data.isoccupant && (
|
{data.isoccupant ? (
|
||||||
<Button.Confirm
|
<Button.Confirm
|
||||||
color={'blue'}
|
color={'blue'}
|
||||||
content={'Connect to VR'}
|
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
act('vr_connect');
|
act('vr_connect');
|
||||||
act('tgui:close');
|
act('tgui:close');
|
||||||
}}
|
}}
|
||||||
icon={'unlock'} />
|
icon={'unlock'}>
|
||||||
)
|
Connect to VR
|
||||||
|| ("You need to be inside the VR sleeper to connect to VR")}
|
</Button.Confirm>
|
||||||
|
) : (
|
||||||
|
"You need to be inside the VR sleeper to connect to VR"
|
||||||
|
)}
|
||||||
</Section>
|
</Section>
|
||||||
{!!data.vr_avatar && (
|
{!!data.vr_avatar && (
|
||||||
<Button
|
<Button
|
||||||
content={"Delete VR avatar"}
|
|
||||||
icon={'recycle'}
|
icon={'recycle'}
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
act('delete_avatar');
|
act('delete_avatar');
|
||||||
}} />
|
}}>
|
||||||
|
Delete VR avatar
|
||||||
|
</Button>
|
||||||
)}
|
)}
|
||||||
</Section>
|
</Section>
|
||||||
</Window.Content>
|
</Window.Content>
|
||||||
|
|||||||
Reference in New Issue
Block a user