This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
Lewisk3's profile picture

Laserbox 2 With New Gui And Shields!

Started by Lewisk3, 04 November 2013 - 11:26 PM
Lewisk3 #1
Posted 05 November 2013 - 12:26 AM
Laserbox 2


installer By Hellkid98 : http://pastebin.com/GyZzJ89T - Fixed :)/>


New Features



Spoiler


Sheilds
Player1 Shield: D
Player2 Shield: L
Max Sheilds: 3

Movement
Player1: W and S
Player2: Up and Down

Shoot Laser:
Player1: LeftShift
Player2:RightShift


Gui :
Brand New look











Edited on 10 November 2013 - 12:45 AM
theHatedOne #2
Posted 05 November 2013 - 10:01 AM
That's cool :D/>
Csstform #3
Posted 05 November 2013 - 11:40 AM
Pastebin?
Lewisk3 #4
Posted 05 November 2013 - 03:47 PM
Laserbox2: http://pastebin.com/y3FE6xcd
Laserbox back: http://pastebin.com/2mpqLzkb
laserbox sprite1: http://pastebin.com/i4QknDa3
laserbox sprite2: http://pastebin.com/bBiewE7C
laserbox sheild: http://pastebin.com/SbLag1ec


Pastebin links
:)/>
TheOddByte #5
Posted 07 November 2013 - 03:42 PM
You should really make an installer when you have multiple files
What's in here? .-.Oh, This is just an example how you can make an installer ;)/>

--# Example installer

local function pGet(hCode,file)

   hResponse = http.get("http://pastebin.com/raw.php?i="..textutils.urlEncode(hCode))
          if hResponse then
         hFile = fs.open(file,"w")
              local sCode = hResponse.readAll()
     hResponse.close()
              hFile.write(sCode)
              hFile.close() --Always important to close file :3

     else 
     error("Error getting the file "..file,0)
          end
end

local files = {
    [1] = {
        name = "LaserBox2",
        code  = "y3FE6xcd",
    },

    [2] = {
        name = "Laserbox_back",
        code  = "2mpqLzkb",
    },

    [3] = {
         name = "Laserbox_sprite1",
         code  = "i4QknDa3",
    },

    [4] = {
        name = "Laserbox_sprite2",
        code  = "bBiewE7C",
    },

    [5] = {
        name = "Laserbox_Shield",
        code  = "SbLag1ec",
    },
}

for i = 1,#files do
    pGet(files[i].code, files[i].name)
end
Lewisk3 #6
Posted 09 November 2013 - 02:35 PM
You should really make an installer when you have multiple files
What's in here? .-.Oh, This is just an example how you can make an installer ;)/>

--# Example installer

local function pGet(hCode,file)

   hResponse = http.get("http://pastebin.com/raw.php?i="..textutils.urlEncode(hCode))
		  if hResponse then
		 hFile = fs.open(file,"w")
			  local sCode = hResponse.readAll()
	 hResponse.close()
			  hFile.write(sCode)
			  hFile.close() --Always important to close file :3

	 else
	 error("Error getting the file "..file,0)
		  end
end

local files = {
	[1] = {
		name = "LaserBox2",
		code  = "y3FE6xcd",
	},

	[2] = {
		name = "Laserbox_back",
		code  = "2mpqLzkb",
	},

	[3] = {
		 name = "Laserbox_sprite1",
		 code  = "i4QknDa3",
	},

	[4] = {
		name = "Laserbox_sprite2",
		code  = "bBiewE7C",
	},

	[5] = {
		name = "Laserbox_Shield",
		code  = "SbLag1ec",
	},
}

for i = 1,#files do
	pGet(files[i].code, files[i].name)
end

Thanks :)/>
P.S im not too experienced with pastebin installers
TheOddByte #7
Posted 09 November 2013 - 03:31 PM
You should really make an installer when you have multiple files
What's in here? .-.Oh, This is just an example how you can make an installer ;)/>

--# Example installer

local function pGet(hCode,file)

   hResponse = http.get("http://pastebin.com/raw.php?i="..textutils.urlEncode(hCode))
		  if hResponse then
		 hFile = fs.open(file,"w")
			  local sCode = hResponse.readAll()
	 hResponse.close()
			  hFile.write(sCode)
			  hFile.close() --Always important to close file :3

	 else
	 error("Error getting the file "..file,0)
		  end
end

local files = {
	[1] = {
		name = "LaserBox2",
		code  = "y3FE6xcd",
	},

	[2] = {
		name = "Laserbox_back",
		code  = "2mpqLzkb",
	},

	[3] = {
		 name = "Laserbox_sprite1",
		 code  = "i4QknDa3",
	},

	[4] = {
		name = "Laserbox_sprite2",
		code  = "bBiewE7C",
	},

	[5] = {
		name = "Laserbox_Shield",
		code  = "SbLag1ec",
	},
}

for i = 1,#files do
	pGet(files[i].code, files[i].name)
end

Thanks :)/>
P.S im not too experienced with pastebin installers
You should change the names in the installer to the corret ones.. It errors if you try to run the main file( I think it is trying to load an image with a different name from what the installer downloaded ) ;)/>
Also, In the main post > Shield*
Edited on 09 November 2013 - 02:33 PM