ShareShortcuts

IsSongPlayingOrPaused

weplaydr
Fazer fork de “IsSongPlayingOrPaused”

Criou algo novo a partir deste atalho? Compartilhe como uma derivação: ela se torna um atalho seu, que você gerencia, e as duas páginas têm links entre si para que weplaydr receba o crédito.

  1. 1Obtenha o atalho e altere-o no app Atalhos. Dê a ele um nome próprio.
  2. 2Compartilhe pelo app Atalhos e copie o link do iCloud.
  3. 3Volte aqui, cole o link e descreva o que mudou, por exemplo: “Adicionei uma etapa que usa a Apple Intelligence para personalizar o texto.”
Downloads
32K
Salvo
1
Ações
15
Categoria
Music
Versão
1.1
Idioma
EN

IsSongPlayingOrPaused 1/0 SHORTCUTS HAS NO NATIVE SUPPORT TO DETERMINE WHETHER OR NOT CURRENT SONG IS PLAYING OR PAUSED. This is carefully crafted to first circumvent possible conversion errors by CASTING PLAYBACK POSITION TO NUMBER (Type); sampling twice; then test whether delta is non-zero.

Novidades

Versão 1.1

An extraneous nop action deleted from script.

Histórico de versões
1.1 23 de mai de 2023

An extraneous nop action deleted from script.

1.0 23 de mai de 2023

First release

O que ele faz

15 ações
  1. Get Current Song
  2. Number
  3. Set Variable
    t0
  4. Comment
    ENABLES SHORTCUTS TO DETERMINE WHETHER IsSongPlayingOrPaused 1/0 APPLE SHORTCUTS HAS NO NATIVE SUPPORT TO DETERMINE WHETHER OR NOT A SONG IS CURRENTLY PLAYING. Tuesday May 23, 2023 WRITTEN BY [email protected] PayPal.Me/Edmonton/10
  5. Nothing
  6. Comment
    The above NOP + Comment increases Time Delta by 100ths of a second
  7. Number
  8. Wait
  9. Get Current Song
  10. Number
  11. Set Variable
    t1
  12. If
  13. Stop and Output
  14. If
  15. Stop and Output

Ver como código
Beta

Todas as ações deste atalho escritas em Cherri, uma linguagem de programação para o app Atalhos. Ótimo para aprender como ele funciona.

#include 'actions/music'
#define color purple
#define glyph circledQuestionMark

const CurrentPlaybackTime = getCurrentSong()
number(CurrentPlaybackTime)
@t0
/*
ENABLES SHORTCUTS TO DETERMINE WHETHER  IsSongPlayingOrPaused   1/0

APPLE SHORTCUTS HAS NO NATIVE SUPPORT TO DETERMINE WHETHER OR NOT A SONG IS CURRENTLY PLAYING. 

Tuesday May 23, 2023 WRITTEN BY [email protected]
PayPal.Me/Edmonton/10

*/
nothing()
// The above NOP + Comment increases Time Delta by 100ths of a second

const Number = 0.5
wait(Number)
const CurrentPlaybackTime1 = getCurrentSong()
@t1 = CurrentPlaybackTime1

if @t1 > @t0 {
	mustOutput("1", "1")
} else {
	mustOutput("0", "0")
}
Abrir no Cherri Playground Descompilado com cherri 2.3.0 (GPL-2.0). Pode precisar de pequenos ajustes antes de compilar.

Avaliações e comentários

Escrever uma avaliação
–
de 5
★★★★★
★★★★
★★★
★★
★
0 ratings

Ainda não há avaliações. Seja o primeiro a compartilhar o que você pensa!

Publicidade

Mais de weplaydr

Ver tudo

Você também pode gostar

Ver tudo
Publicidade