Discuss Scratch

y20070112
Scratcher
100+ posts

Scratch2.0をModする会

ディレクトリをscratch-flashのあるところにする。
cd <path to source code>
(例)desktop/Scratch/Modding/scratch-flashなら
cd desktop/Scratch/modding/scratch-flash
↑どう言う事??????????
できナィィィィィィィィィl
y20070112
Scratcher
100+ posts

Scratch2.0をModする会

y20070112 wrote:

ディレクトリをscratch-flashのあるところにする。
cd <path to source code>
(例)desktop/Scratch/Modding/scratch-flashなら
cd desktop/Scratch/modding/scratch-flash
↑どう言う事??????????
できナィィィィィィィィィl
問題解決

FAILURE:例外が発生してビルドに失敗しました。

* 何が悪かったのか:
'10'からJavaバージョンを判別できませんでした。

*試してみてください:
スタックトレースを取得するには、–stacktraceオプションを指定して実行します。より多くのログ出力を得るには、–infoまたは–debugオプションを指定して実行します。
と出てきてできない。()u @98t @@90n9 figh
su2014080902
Scratcher
100+ posts

Scratch2.0をModする会

y20070112 wrote:

ディレクトリをscratch-flashのあるところにする。
cd <path to source code>
(例)desktop/Scratch/Modding/scratch-flashなら
cd desktop/Scratch/modding/scratch-flash
↑どう言う事??????????
できナィィィィィィィィィl
desktop/Scratch/Modding/scratch-flashはパスとして正確な表記ではありません。
また、あまりデスクトップ下にソフトウェア置くのは動作が不安定になりおすすめできません。
Cドライブ直下にフォルダーを作り、「C:\Scratch\Modding\scratch-flash」の位置に配置し直してみては。

・・・と、その前に、あなたの使っているOSはWindowsですか?Macintoshですか?Linuxですか?

Last edited by su2014080902 (March 30, 2018 12:28:30)

y20070112
Scratcher
100+ posts

Scratch2.0をModする会

su2014080902 wrote:

y20070112 wrote:

ディレクトリをscratch-flashのあるところにする。
cd <path to source code>
(例)desktop/Scratch/Modding/scratch-flashなら
cd desktop/Scratch/modding/scratch-flash
↑どう言う事??????????
できナィィィィィィィィィl
desktop/Scratch/Modding/scratch-flashはパスとして正確な表記ではありません。
また、あまりデスクトップ下にソフトウェア置くのは動作が不安定になりおすすめできません。
Cドライブ直下にフォルダーを作り、「C:\Scratch\Modding\scratch-flash」の位置に配置し直してみては。

・・・と、その前に、あなたの使っているOSはWindowsですか?Macintoshですか?Linuxですか?
あ、Macです。
su2014080902
Scratcher
100+ posts

Scratch2.0をModする会

y20070112 wrote:

あ、Macです。
①Gitインストールの確認 ターミナルを起動し、
$ git –version
と入力して実行
『git version 2.5.●』のようなバージョン情報が表示されなく、『コマンドライン・デベロッパー・ツールが必要です』と出たらインストールをクリック。インストールが終了したら、再度$ git –versionを実行。それでも表示されない場合、Gitの公式サイトからGitをインストール。

②JDKのインストールの確認 ターミナルを起動し、
java -version
と入力して実行。
Java(TM) SE Runtime Environment (build “バージョン”)
のような文が中に入っていたらインストールされている。(“バージョン”の部分にはインストールされているJDKのバージョンが入ります)
無い場合、こちらを参考にJDKのインストールをしてください。

③Gradleのインストールの確認 ターミナルを起動し、
$ gradle –version
を入力して実行。『Gradle 2.14』のように出たらインストールされている。
無い場合、こちらを参考にインストールする。

④Scratchのダウンロード先のフォルダー(以下、「Scratchソースフォルダ」)を作成し、右クリック→Open Terminal hereをクリック。出てきたターミナルに
git clone https://github.com/LLK/scratch-flash
を入力し実行。Scratchソースフォルダに「scratch-flash」フォルダがあると思うので、そのフォルダーを右クリック→Open Terminal hereをクリック。
./gradlew build
を入力し実行。待っていて「BUILD SUCCESSFUL」と出たら成功。Scratchソースフォルダに「build」フォルダがあり、その中にScratch.swfが入っています。

これで終了です。お疲れ様でした。

Last edited by su2014080902 (March 31, 2018 22:32:11)

kesarenai
Scratcher
33 posts

Scratch2.0をModする会

ビルドするときに、
* Where:
Script 'C:\Users\ユーザー\Desktop\Project\scratch-flash\scratch.gradle' line: 24

* What went wrong:
A problem occurred evaluating script.
> Cannot run program "git" (in directory "C:\Users\ユーザー\Desktop\Project\scratch-flash"): CreateProcess error=2, 指定されたファイルが見つかりません。

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
と出てきてしまいます.翻訳していろいろ考えたのですがよくわかりませんでした.
どうすればいいですか?
gitもgradleも一応インストール済みです.
apple502j
Scratcher
1000+ posts

Scratch2.0をModする会

kesarenai wrote:

ビルドするときに、
* Where:
Script 'C:\Users\ユーザー\Desktop\Project\scratch-flash\scratch.gradle' line: 24

* What went wrong:
A problem occurred evaluating script.
> Cannot run program "git" (in directory "C:\Users\ユーザー\Desktop\Project\scratch-flash"): CreateProcess error=2, 指定されたファイルが見つかりません。

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
と出てきてしまいます.翻訳していろいろ考えたのですがよくわかりませんでした.
どうすればいいですか?
gitもgradleも一応インストール済みです.
pathに入れましたか
kesarenai
Scratcher
33 posts

Scratch2.0をModする会

apple502j wrote:

kesarenai wrote:

gitもgradleも一応インストール済みです.
pathに入れましたか
どちらも入れました.

Last edited by kesarenai (April 2, 2018 00:48:23)

apple502j
Scratcher
1000+ posts

Scratch2.0をModする会

やってたのはgit cloneですか?
もしそうならGit Bashからやることをおすすめします
nagacyan
Scratcher
100+ posts

Scratch2.0をModする会

build/11.6/Scratch.swfを作るときにこんなエラーが出ました。
FAILURE: Build failed with an exception.

* What went wrong:
Could not determine java version from '10'.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
これはどういう意味ですか。
そしてどうやったらswfを作ることが出来ますか。
apple502j
Scratcher
1000+ posts

Scratch2.0をModする会

nagacyan wrote:

build/11.6/Scratch.swfを作るときにこんなエラーが出ました。
FAILURE: Build failed with an exception.

* What went wrong:
Could not determine java version from '10'.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
これはどういう意味ですか。
そしてどうやったらswfを作ることが出来ますか。
JDKをいれていますか
nagacyan
Scratcher
100+ posts

Scratch2.0をModする会

apple502j wrote:

nagacyan wrote:

build/11.6/Scratch.swfを作るときにこんなエラーが出ました。
FAILURE: Build failed with an exception.

* What went wrong:
Could not determine java version from '10'.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
これはどういう意味ですか。
そしてどうやったらswfを作ることが出来ますか。
JDKをいれていますか
入れています。
nagacyan
Scratcher
100+ posts

Scratch2.0をModする会

上の問題は解決しましたが、
次はこれです。
FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':compileFlex'.
> java.net.MalformedURLException: unknown protocol: c

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

BUILD FAILED
これはどういう意味ですか。
'compileFlex'とはなんですか。
inoking
Scratcher
1000+ posts

Scratch2.0をModする会

nagacyan wrote:

上の問題は解決しましたが、
次はこれです。
回答でなくてすみません、
どうやって前の問題を解決したのかも書いてもらうと
のちのち他の人のためになりますよ。
nagacyan
Scratcher
100+ posts

Scratch2.0をModする会

了解です。
gradleがJavaのバージョンに対応していなかったようなので、
Javaをver.10から8に引き下げました。
ですが今度は別の問題が発生してしまった訳です。
inoking
Scratcher
1000+ posts

Scratch2.0をModする会

nagacyan wrote:

了解です。
gradleがJavaのバージョンに対応していなかったようなので、
Javaをver.10から8に引き下げました。
ですが今度は別の問題が発生してしまった訳です。
情報ありがとうございます。

これはなかなか気付くのが難しそうですね。
よく気付きましたね!
suujikunn
Scratcher
40 posts

Scratch2.0をModする会

いろいろ試してみた
$ gradlew.bat build
bash: gradlew.bat: command not found
$ ./gradlew.bat build

FAILURE: Build failed with an exception.

* What went wrong:
Could not determine java version from ‘9.0.1’.

* Try:
Run with –stacktrace option to get the stack trace. Run with –info or –debug option to get more log output.
$ ./gradlew build

FAILURE: Build failed with an exception.

* What went wrong:
Could not determine java version from ‘9.0.1’.

* Try:
Run with –stacktrace option to get the stack trace. Run with –info or –debug option to get more log output.

ナルホド、ワカラン
My browser / operating system: Windows NT 10.0, Opera 52.0.2871.64, Flash 29.0 (release 0)
mii-10
Scratcher
100+ posts

Scratch2.0をModする会

要望があったので
gotohttp://
のソースコードを書かせていただきます。ただし簡略化できる可能性はあります。
specs.asの中に
		["goto http:// %s",						" ", 6, "gotoUrl"],
		["goto http:// %s",						" ", 106, "gotoUrl"],
を追加(カテゴリーわけに従う方が見やすい。)
Interpreter.asに
	import flash.net.navigateToURL;
	import flash.net.URLRequest;
を追加(ただし自分はimport flash.net.*;で一括ロード。参考までに)
その後
		primTable["gotoUrl"]			= primGotourl;
	private function primGotourl(b:Block):void{
		var url:String = "http://" + arg(b, 0) ;
		var urlrequest:URLRequest = new URLRequest(url);
		navigateToURL (urlrequest);
	}
も追加することで実装できます。
日本語翻訳は
正しいとは限らない自己翻訳
msgid "goto http:// %s"
msgstr "http(s):// %s を開く"
で(正しいとは限らない自己翻訳)を入れた.poファイルでできます。
(万が一コードに不備がありましたら連絡を。)
(ほかに自分のmod内容で知りたいコードがあれば連絡を。)

Last edited by mii-10 (June 4, 2018 11:34:41)

apple502j
Scratcher
1000+ posts

Scratch2.0をModする会

Javaのバージョン8を試してください
jun50
Scratcher
1000+ posts

Scratch2.0をModする会

Windows1000000 wrote:

mii-10 wrote:

要望があったので
gotohttp://
のソースコードを書かせていただきます。ただし簡略化できる可能性はあります。
specs.asの中に
		["goto http:// %s",						" ", 6, "gotoUrl"],
		["goto http:// %s",						" ", 106, "gotoUrl"],
を追加(カテゴリーわけに従う方が見やすい。)
Interpreter.asに
	import flash.net.navigateToURL;
	import flash.net.URLRequest;
を追加(ただし自分はimport flash.net.*;で一括ロード。参考までに)
その後
		primTable["gotoUrl"]			= primGotourl;
	private function primGotourl(b:Block):void{
		var url:String = "http://" + arg(b, 0) ;
		var urlrequest:URLRequest = new URLRequest(url);
		navigateToURL (urlrequest);
	}
も追加することで実装できます。
日本語翻訳は
正しいとは限らない自己翻訳
msgid "goto http:// %s"
msgstr "http(s):// %s を開く"
で(正しいとは限らない自己翻訳)を入れた.poファイルでできます。
(万が一コードに不備がありましたら連絡を。)
(ほかに自分のmod内容で知りたいコードがあれば連絡を。)
すみません。Interpreter.asとspecs.asはどこのフォルダーにあるのですか?
確かsrcだったと思います。

Powered by DjangoBB