ComputerCraft Forums

ComputerCraft => Programs => Command Programs => Topic started by: KingofGamesYami on Aug 13, 2018, 01:25 am

Title: Flag Displayer
Post by: KingofGamesYami on Aug 13, 2018, 01:25 am
Reposted from here (http://www.computercraft.info/forums2/index.php?/topic/26807-flag-displayer/)

This is a simple program to display a flag behind a player using particles.
pastebin get FSzi7xKP (http://pastebin.com/FSzi7xKP) flag
There is a bit of setup involved. The program requires two APIs, commandsPlus (https://forums.computercraft.cc/index.php?topic=27.0) and partTerm (http://www.computercraft.info/forums2/index.php?/topic/26705-mc18-partterm-api/). In addition to those two, it reqiures a 49 x 13 image named '.flag' - I have an American Flag (cKBWFrTW) (http://pastebin.com/cKBWFrTW).
When you start the program, be sure to stand within 10 blocks of the command computer, so that it may recognize you as the player activating the program. If other players are within that radius, ask them to leave or the program may be confused. Alternatively, edit the program at this line:
Code Select
local player = commandsPlus.getNearbyPlayers( "10 " )[1]
And add your name, eg:
Code Select
local player = "KingofGamesYami"
Thanks a ton to BB for his wonderful API partTerm and the assistance he has provided for me in using it.

Unfortunately, the nature of this program does not allow very good screenshots. This is the best I could do.
(http://i.imgur.com/cqvrTyE.png)