こんにちわ(´∀`)
オルレフです。
今日の記事の電光掲示板プログラムですが見たいという方もいらっしゃいましたので臨時更新として公開します(´∀`)
オルレフです。
今日の記事の電光掲示板プログラムですが見たいという方もいらっしゃいましたので臨時更新として公開します(´∀`)
まず上のSSに映っている改札口用のプログラムです。
term.setBackgroundColor(128)
term.clear()
term.setTextColor(2)
term.setCursorPos(1,1)--setCursorPos(X,Y)
print("")
term.setTextColor(2)
term.setCursorPos(6,1)--setCursorPos(X,Y)
print("01")
term.setTextColor(32)
term.setCursorPos(9,1)--setCursorPos(X,Y)
print("NorthLine")
term.setTextColor(16384)
term.setCursorPos(19,1)
print("Exp.")
term.setTextColor(1)
term.setCursorPos(25,1)
print("12:00 Kusabira")
term.setTextColor(2)
term.setCursorPos(1,2)--setCursorPos(X,Y)
print("Next")
term.setTextColor(2)
term.setCursorPos(6,2)--setCursorPos(X,Y)
print("01")
term.setTextColor(32)
term.setCursorPos(9,2)--setCursorPos(X,Y)
print("NorthLine")
term.setTextColor(16384)
term.setCursorPos(19,2)
print("Local")
term.setTextColor(1)
term.setCursorPos(25,2)
print("12:10 Kusabira")
term.setTextColor(2)
term.setCursorPos(1,3)--setCursorPos(X,Y)
print("")
term.setTextColor(2)
term.setCursorPos(6,3)--setCursorPos(X,Y)
print("02")
term.setTextColor(32)
term.setCursorPos(9,3)--setCursorPos(X,Y)
print("NorthLine")
term.setTextColor(16384)
term.setCursorPos(19,3)
print("Local")
term.setTextColor(1)
term.setCursorPos(25,3)
print("12:05 Kayano")
term.setTextColor(2)
term.setCursorPos(1,4)--setCursorPos(X,Y)
print("Next")
term.setTextColor(2)
term.setCursorPos(6,4)--setCursorPos(X,Y)
print("02")
term.setTextColor(32)
term.setCursorPos(9,4)--setCursorPos(X,Y)
print("NorthLine")
term.setTextColor(16384)
term.setCursorPos(19,4)
print("Exp.")
term.setTextColor(1)
term.setCursorPos(25,4)
print("12:15 Kayano")
ここまで。
基本的に色指定、座標指定、表示する文字となっています。
4行共通にするために何も出していない部分も何も出さない指定が入っている部分もあります。
次に1番線の電光掲示板です。
基本的に色指定、座標指定、表示する文字となっています。
4行共通にするために何も出していない部分も何も出さない指定が入っている部分もあります。
次に1番線の電光掲示板です。
term.setBackgroundColor(128)
term.clear()
term.setTextColor(16)
term.setCursorPos(1,1)--setCursorPos(X,Y)
print("Track")
term.setTextColor(2)
term.setCursorPos(7,1)--setCursorPos(X,Y)
print("01")
term.setTextColor(32)
term.setCursorPos(1,2)--setCursorPos(X,Y)
print("North")
term.setCursorPos(8,2)--setCursorPos(X,Y)
print("Line")
term.setTextColor(2)
term.setCursorPos(1,3)--setCursorPos(X,Y)
print("")
term.setTextColor(16384)
term.setCursorPos(6,3)
print("Exp.")
term.setTextColor(1)
term.setCursorPos(11,3)
print("12:00 Kusabira")
term.setTextColor(2)
term.setCursorPos(1,4)--setCursorPos(X,Y)
print("Next")
term.setTextColor(16384)
term.setCursorPos(6,4)
print("Local")
term.setTextColor(1)
term.setCursorPos(11,4)
print("12:10 Kusabira")
ここまで。
何番線の表示と路線名を上部にだして他の項目を3,4行目に列車情報を出しています。
基本的に1番線と全く同じです。
2014/04/20追記
実行方法をコメントにいただいていたのに記事に明記していなかったので追記
何番線の表示と路線名を上部にだして他の項目を3,4行目に列車情報を出しています。
基本的に1番線と全く同じです。
term.setBackgroundColor(128)
term.clear()
term.setTextColor(16)
term.setCursorPos(1,1)--setCursorPos(X,Y)
print("Track")
term.setTextColor(2)
term.setCursorPos(7,1)--setCursorPos(X,Y)
print("02")
term.setTextColor(32)
term.setCursorPos(1,2)--setCursorPos(X,Y)
print("North")
term.setCursorPos(8,2)--setCursorPos(X,Y)
print("Line")
term.setTextColor(2)
term.setCursorPos(1,3)--setCursorPos(X,Y)
print("")
term.setTextColor(16384)
term.setCursorPos(6,3)
print("Local")
term.setTextColor(1)
term.setCursorPos(11,3)
print("12:05 Kayano")
term.setTextColor(2)
term.setCursorPos(1,4)--setCursorPos(X,Y)
print("Next")
term.setTextColor(16384)
term.setCursorPos(6,4)
print("Exp.")
term.setTextColor(1)
term.setCursorPos(11,4)
print("12:15 Kayano")
ここまで。
ここまで。
2014/04/20追記
実行方法をコメントにいただいていたのに記事に明記していなかったので追記
実行するときは、こんな感じにmonitor モニターの方向 プログラム名Ex: monitor right tで実行してみてください。
今回の設置方法だと「monitor bottom [プログラム名]」となります。
また、改札口用のモニタは4つのモニタを使用、各乗り場の方は3つで作成しています。
モニタの数が多いぶんには問題ありませんが少ない場合表示がおかしくなりますのでご注意下さい(´∇`)
追記ここまで。
電光掲示板のプログラムをダウンロードできるようになりました(`・ω・´)
→こちらのリンクからどうぞ
また、改札口用のモニタは4つのモニタを使用、各乗り場の方は3つで作成しています。
モニタの数が多いぶんには問題ありませんが少ない場合表示がおかしくなりますのでご注意下さい(´∇`)
追記ここまで。
電光掲示板のプログラムをダウンロードできるようになりました(`・ω・´)
→こちらのリンクからどうぞ
ほんとはプログラムをループさせてゲーム内時刻で表示を変えたいのですがまだ拡張するだろうと今のところ放置していますw
ほんとただのベタうちですが私と同じ初心者の方には参考になるかもしれませんので公開しておきます(´∀`)
それではまた明日ヽ(゚∀゚)ノ
ブログランキングに登録しています。クリックしていただくと喜びますヽ(゚∀゚)ノ
Minecraft ブログランキングへ
にほんブログ村
ほんとただのベタうちですが私と同じ初心者の方には参考になるかもしれませんので公開しておきます(´∀`)
それではまた明日ヽ(゚∀゚)ノ
ブログランキングに登録しています。クリックしていただくと喜びますヽ(゚∀゚)ノ
Minecraft ブログランキングへ
にほんブログ村
このブログにコメントするにはログインが必要です。
さんログアウト
この記事には許可ユーザしかコメントができません。