diff --git a/.gitignore b/.gitignore index ca4821a..3fde2cd 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,3 @@ token.json +*.syu.is.json +*.syui.ai.json diff --git a/README.md b/README.md index 10cf2ad..6245c3a 100644 --- a/README.md +++ b/README.md @@ -270,11 +270,11 @@ pixelstreaming自体は、frontendを改造して、そのままゲーム画面 そして、そんなhololiveもyoutubeからの収益は大きくなくて、グッズ販売が大きかった。これからさらにyoutubeはいろいろな理由をつけてクリエイターの報酬を下げていくと思われます。これはamazonのアソシエイトが流行ったときに起こったことにとても良く似ていると感じます。 -つまり、今、twitterやyoutubeで人気者になってお金を稼ごうというのは、とても大変で、かつ将来性に期待できないということ。ここで利益を受けられるのは、昔からそこで活動していた開拓者となるでしょう。今からの参入は難しいということです。 +つまり、今、twitterやyoutubeで人気者になってお金を稼ごうというのは、今から始めるのはとても大変で、かつ将来性に期待できないと思います。ここで利益を受けられるのは、昔からそこで活動していた開拓者になるでしょう。今からの参入は難しいということです。 -つまり、これらのプラットフォームで起こりえるのは、これまで人気だった人がますます人気になること。そして、その人達でさえ少しずつgoogleからの配分を少なくされていくことだと予測されます。 +つまり、これらのプラットフォームで起こりえるのは、これまで人気だった人がますます人気になること。そして、その人達でさえ少しずつgoogleからの配分が少なくされていくことだと予測されます。 -どちらにせよ、今参入しても拡散できず、拡散したとして収益につながらないのであれば、収益化に関して他の方法を模索していくべきと考えています。 +どちらにせよ、今参入しても拡散できず、拡散したところで収益につながらない可能性が極めて高いかと思います。つまり、収益化に関しては他の方法を模索していくべきと考えられます。 したがって、今のところ、収益は、ゲームのガチャとグッズ販売、この2つに焦点を当てる。その方向で考えています。 diff --git a/bin/verse.zsh b/bin/verse.zsh index 6d5c114..b67fe34 100755 --- a/bin/verse.zsh +++ b/bin/verse.zsh @@ -1,17 +1,25 @@ #!/bin/zsh function at_env_arg() { - handle=syui.syui.ai - col=ai.syui.verse.user - rkey=self host=syu.is + handle=ai.syui.ai + col=ai.syui.verse.user } function at_env() { + + if [ -n "$1" ];then + handle=$1 + fi + if [ -n "$2" ];then + col=$2 + fi + d=${0:a:h} + cd $d dd=${0:a:h:h} pds=$host - f=$d/token.json + f=$d/${handle}.json if [ ! -f $f ];then echo password read password @@ -21,14 +29,17 @@ function at_env() { refresh=`cat $f|jq -r .refreshJwt` fi j_verse=`cat $dd/json/verse.json` - j_user=`cat $dd/json/user.json` + j_user=`cat $dd/json/${handle}.user.json` case $col in ai.syui.verse) j=${j_verse} + rkey=self ;; ai.syui.verse.user) j=${j_user} + rkey=self + rkey=`echo $did|cut -d : -f 3` ;; esac @@ -82,16 +93,36 @@ function at_put_record() { "rkey": $rkey, "record": $record }') - - echo $json if echo $json|jq . ;then t=`curl -sL -X POST -H "Content-Type: application/json" -H "Authorization: Bearer $access" -d "$json" $url` echo $t|jq . fi } +function at_delete_record() { + req=com.atproto.repo.DeleteRecord + url=https://$pds/xrpc/$req + echo collection: + read col + echo rkey: + read rkey + json="{\"collection\":\"$col\", \"rkey\":\"$rkey\", \"repo\":\"$handle\"}" + if echo $json|jq . ;then + t=`curl -sL -X POST -H "Content-Type: application/json" -H "Authorization: Bearer $access" -d $json $url` + echo $t|jq . + fi +} + at_env_arg -at_env +at_env $1 $2 at_create_session at_refresh_session -at_put_record + +case $1 in + d) + at_delete_record + ;; + *) + at_put_record + ;; +esac diff --git a/json/ai.syui.ai.user.json b/json/ai.syui.ai.user.json new file mode 100644 index 0000000..89ecbbb --- /dev/null +++ b/json/ai.syui.ai.user.json @@ -0,0 +1,14 @@ +{ + "character": [ + { "id": 0, "cp": 100 , "mode": 2, "unique": false }, + { "id": 1, "cp": 100 , "mode": 0, "unique": false } + ], + "item": [ + { "id": 0, "cp": 0 }, + { "id": 1, "cp": 0 } + ], + "card": [ + { "id": 0, "cp": 0 }, + { "id": 1, "cp": 0 } + ] +} diff --git a/json/syui.syui.ai.user.json b/json/syui.syui.ai.user.json new file mode 100644 index 0000000..3f97fea --- /dev/null +++ b/json/syui.syui.ai.user.json @@ -0,0 +1,11 @@ +{ + "character": [ + { "id": 1, "cp": 100 , "mode": 0, "unique": false } + ], + "item": [ + { "id": 1, "cp": 0 } + ], + "card": [ + { "id": 1, "cp": 0 } + ] +} diff --git a/json/user.json b/json/user.json index 32e2ccd..89ecbbb 100644 --- a/json/user.json +++ b/json/user.json @@ -1,7 +1,7 @@ { "character": [ - { "id": 0, "cp": 100, "unique": true }, - { "id": 1, "cp": 100 , "unique": false } + { "id": 0, "cp": 100 , "mode": 2, "unique": false }, + { "id": 1, "cp": 100 , "mode": 0, "unique": false } ], "item": [ { "id": 0, "cp": 0 },