Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Jits msg in game setup #25

Closed
wants to merge 10 commits into from

Conversation

sl5net
Copy link

@sl5net sl5net commented May 21, 2023

adds a jitsi command in the game setup.

"/jitsi": "meet.jit.si/anyNameYoutWantHere"

it generates a unique but short, human readable jitsi-link and opens it.
then renames the looby name with included jitsi link.

@nanihadesuka nanihadesuka self-requested a review May 21, 2023 19:46
@nanihadesuka
Copy link
Owner

Code needs some touches, will check this next week

@@ -1,4 +1,4 @@

var linkidShort = Date.now().toString().substring(10);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Move inside the g_NetworkCommands["/jitsi"]

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

its global. because the link should stay the same during the config and the game. its generated from milisecond from now.

@@ -268,7 +268,8 @@ g_NetworkCommandsDescriptions = Object.assign(g_NetworkCommandsDescriptions,{
"/ban": "Ban player",
"/banspecs": "Ban all specs",
"/list": "List all the players and observers currently here",
"/clear": "Clear the chat comments"
"/clear": "Clear the chat comments",
"/jitsi": "meet.jit.si/anyNameYoutWantHere"
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

align spaces with others

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bad description. Tell what is does, the use.
example: "Create a game videocall. Uses jitsi (meet.jit.si) service"

Comment on lines +358 to +373
// selfMessage(`meet.jit.si/anyNameYoutWantHere`);
selfMessage(
`Jitsi Meet is a fully encrypted, 100% open source video conferencing solution that you can use all day, every day, for free — with no account needed.`
)


let gitHubLinkAutoCivModificationSL5 = 'https://github.com/sl5net/autociv';

let textBest = `Jitsi is best for having a quick team call without setup process. could used as audio chat for you 0ad-team. `
selfMessage(
textBest
)

selfMessage(
`write /link to open a link in your WebBrowser if you have autoCiv-mod installed to open a link more easy.`
)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove all this, not necessary for the user

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i need to explain very often to user what it is. so i don't want remove it.

Comment on lines +377 to +384
let linkTeam1example = `https://meet.jit.si/0ad${linkidShort}team123`
selfMessage(
` recommendation: send later in your private team-game-chat a other unique link for audio chat. Example: ${linkTeam1example}`
)

selfMessage(
` this autoCiv-mod modification you could donwload here: ${gitHubLinkAutoCivModificationSL5}`
)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove also, unnecessary for the user.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

its useful information for the user

Comment on lines +387 to +393
let population = 250
game.set.population(population)

g_GameSettings.startingResources.resources = 200
game.updateSettings()

selfMessage(linkLong)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove, this is not part of the command

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you are right. its not match to the title of the command.

Comment on lines +396 to +399
// let gameTextJitsiExplainded = `want use Jitsi as a fully encrypted, open source video conferencing, with no account needed.`
// gameText = ` ${textBest} ${linkLong} `;
let gameText = `jitsi | ${textBest} ${linkLong}`
return setGameNameInLobby(gameText);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is also not part of the command

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the idea is that is visible from outside.

@nanihadesuka
Copy link
Owner

Looking at the feature itself and functionality I think it doesn't make sense to add it as a command. To me it looks easier just to share the link with other people directly and you still have the problem of sharing it.

Thanks for the effort. But, sorry, won't merge in the current form.

An more promising idea would be to have an GUI integration where all the players have a "button" to join the host jit.si session but this can't be done with a mod if you want all players to have it (I recommend asking the official 0ad team for that)

Cheers and thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants