RatcheT2497, on 30 August 2013 - 02:42 PM, said:
So I posted 3 zero-width spaces instead:
https://en.wikipedia...ero-width_space
There have been 73 items by Jan (Search limited from 10-February 22)
Posted by
Jan
on 30 August 2013 - 05:29 PM
in
Forum Games
RatcheT2497, on 30 August 2013 - 02:42 PM, said:
Posted by
Jan
on 30 August 2013 - 02:18 PM
in
Forum Games
Posted by
Jan
on 08 May 2013 - 02:05 PM
in
General
diegodan1893, on 08 May 2013 - 12:51 PM, said:
Left4Cake, on 08 May 2013 - 01:00 PM, said:
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++/000000000abca02000000000000000000000000000000000000000000000000000000000000000000000000000000000000000444333444444440000000000000000000000000000000000000440000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/f222ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff999999999fffffffffffffffffffffffffffffffffffffffff323232aafffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff/18/4/0/f/true/screenshot.png)
Posted by
Jan
on 08 May 2013 - 08:52 AM
in
General
GravityScore, on 08 May 2013 - 08:49 AM, said:
Jan, on 07 May 2013 - 05:01 PM, said:
colors = new String[16]; colors[15] = "255,255,255"; // White colors[14] = "235,136,68"; // Orange colors[13] = "195,84,205"; // Magenta colors[12] = "102,137,211"; // Light blue colors[11] = "222,222,108"; // Yellow colors[10] = "65,205,52"; // Lime colors[9] = "216,129,152"; // Pink colors[8] = "67,67,67"; // Gray colors[7] = "153,153,153"; // Light gray colors[6] = "40,118,151"; // Cyan colors[5] = "123,47,190"; // Purple colors[4] = "37,49,146"; // Blue colors[3] = "81,48,26"; // Brown colors[2] = "59,81,26"; // Green colors[1] = "179,49,44"; // Red colors[0] = "0,0,0"; // Black
Posted by
Jan
on 08 May 2013 - 08:43 AM
in
General
Posted by
Jan
on 07 May 2013 - 05:51 PM
in
General
D3matt, on 07 May 2013 - 05:39 PM, said:
Options +FollowSymlinks RewriteEngine on RewriteRule ^trick/([^/]+)/([^/]+)/([^/]+).png screenshot.php?w=$1&h=$2&t=$3 [NC] DirectoryIndex screenshot.phpi'll update the lua program tomorrow I think
Posted by
Jan
on 07 May 2013 - 05:01 PM
in
General

http://janvanrosmalen.com/ccrender/color/51/19/+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++XX+++++++++++++++++++++++++++++++++++++++++++++++++++%5BSave%5D+Exit++++++++++++++++++++++++++++++++++++++++/888888888888888888888888888888888888888888888888800888888888888888888888888888888888888888888888888800888888888888888888888888888888888888888888888888800888888888888888888888888888888888888888888888888800888888888888888888888888888888888888888888888888800888888888888888888888888888888888888888888888888800888888888888888888888888888888888888888888888888800888888888888888888888888888888888888888888888888800888888888888888888888888888888888888888888888888800888888888888888888888888888888888888888888888888800888888888888888888888888888888888888888888888888800888888888888888888888888888888888888888888888888800888888888888888888888888888888888888888888888888800888888888888888888888888888888888888888888888888800888888888888888888888888888888888888888888888888800888888888888888888888888888888888888888888888888800888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888400004000000888888888888888888888888888888888888888/000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011000000000000000000000000000000000000000000000000022000000000000000000000000000000000000000000000000033000000000000000000000000000000000000000000000000044000000000000000000000000000000000000000000000000055000000000000000000000000000000000000000000000000066000000000fff0fffffffffffff00000000000000000000000770000fff0f00000000ffff00000ffffff0000000000000000088fff000000000000fff00ff000000000ffff0000000000000099f00000000000000f00000f0000000000000ff000000000000aaf000000000000000fffffff00000000ffffff000000000000bbff00000000000fffff000fffffff0f0000000000000000000cc0fff00000000f0000ff00000ff000f0000000ff0000000000dd000fffff0000f00000ffff0f0fff000000000000000000000ee0000000fffffffff0000ff00000ff00000000000000000000ff0000000000000000ffffffffffffff0fff0fffff0000000000000000000000000000ffff0000000ff0000000000000000000f0888888888888888888888888888888888888888888888888888/13/19/0/8/false/screenshot.pngNow you are probably thinking: how did he generate the link?

pastebin get BCbdfzsY screenshot
-- Version 2
term.clear()
term.setCursorPos(1,1)
-- Uses Gopher's redirect buffer api v1.2
-- http://www.computercraft.info/forums2/index.php?/topic/5130-gophers-apis-new-ggui-beta-goroutine-redirect-ctrlkeys/page__hl__gopheratl
local trueCursor={term.getCursorPos()}
local redirectBufferBase = {
write=
function(buffer,...)
local cy=buffer.curY
if cy>0 and cy<=buffer.height then
local text=table.concat({...}," ")
local cx=buffer.curX
local px, py
if buffer.isActive and not buffer.cursorBlink then
term.native.setCursorPos(cx+buffer.scrX, cy+buffer.scrY)
end
for i=1,#text do
if cx<=buffer.width then
local curCell=buffer[cy][cx]
local char,textColor,backgroundColor=string.char(text:byte(i)),buffer.textColor,buffer.backgroundColor
if buffer[cy].isDirty or curCell.char~=char or curCell.textColor~=textColor or curCell.backgroundColor~=backgroundColor then
buffer[cy][cx].char=char
buffer[cy][cx].textColor=textColor
buffer[cy][cx].backgroundColor=backgroundColor
buffer[cy].isDirty=true
end
end
cx=cx+1
end
buffer.curX=cx
if buffer.isActive then
buffer.drawDirty()
if not buffer.cursorBlink then
trueCursor={cx+buffer.scrX-1,cy+buffer.scrY-1}
term.native.setCursorPos(unpack(trueCursor))
end
end
end
end,
setCursorPos=
function(buffer,x,y)
buffer.curX=math.floor(x)
buffer.curY=math.floor(y)
if buffer.isActive and buffer.cursorBlink then
term.native.setCursorPos(x+buffer.scrX-1,y+buffer.scrY-1)
trueCursor={x+buffer.scrX-1,y+buffer.scrY-1}
end
end,
getCursorPos=
function(buffer)
return buffer.curX,buffer.curY
end,
scroll=
function(buffer,offset)
for j=1,offset do
local temp=table.remove(buffer,1)
table.insert(buffer,temp)
for i=1,#temp do
temp[i].char=" "
temp[i].textColor=buffer.textColor
temp[i].backgroundColor=buffer.backgroundColor
end
end
if buffer.isActive then
term.redirect(term.native)
buffer.blit()
term.restore()
end
end,
isColor=
function(buffer)
return buffer._isColor
end,
isColour=
function(buffer)
return buffer._isColor
end,
clear=
function(buffer)
for y=1,buffer.height do
for x=1,buffer.width do
buffer[y][x]={char=" ",textColor=buffer.textColor,backgroundColor=buffer.backgroundColor}
end
end
if buffer.isActive then
term.redirect(term.native)
buffer.blit()
term.restore()
end
end,
clearLine=
function(buffer)
local line=buffer[buffer.curY]
local fg,bg = buffer.textColor, buffer.backgroundColor
for x=1,buffer.width do
line[x]={char=" ",textColor=fg,backgroundColor=bg}
end
buffer[buffer.curY].isDirty=true
if buffer.isActive then
buffer.drawDirty()
end
end,
setCursorBlink=
function(buffer,onoff)
buffer.cursorBlink=onoff
if buffer.isActive then
term.native.setCursorBlink(onoff)
if onoff then
term.native.setCursorPos(buffer.curX,buffer.curY)
trueCursor={buffer.curX,buffer.curY}
end
end
end,
getSize=
function(buffer)
return buffer.width, buffer.height
end,
setTextColor=
function(buffer,color)
buffer.textColor=color
if buffer.isActive then
if term.native.isColor() or color==colors.black or color==colors.white then
term.native.setTextColor(color)
end
end
end,
setTextColour=
function(buffer,color)
buffer.textColor=color
if buffer.isActive then
if term.native.isColor() or color==colors.black or color==colors.white then
term.native.setTextColor(color)
end
end
end,
setBackgroundColor=
function(buffer,color)
buffer.backgroundColor=color
if buffer.isActive then
if term.native.isColor() or color==colors.black or color==colors.white then
term.native.setBackgroundColor(color)
end
end
end,
setBackgroundColour=
function(buffer,color)
buffer.backgroundColor=color
if buffer.isActive then
if term.native.isColor() or color==colors.black or color==colors.white then
term.native.setBackgroundColor(color)
end
end
end,
resize=
function(buffer,width,height)
if buffer.width~=width or buffer.height~=height then
local fg, bg=buffer.textColor, buffer.backgroundColor
if width>buffer.width then
for y=1,buffer.height do
for x=#buffer[y]+1,width do
buffer[y][x]={char=" ",textColor=fg,backgroundColor=bg}
end
end
end
if height>buffer.height then
local w=width>buffer.width and width or buffer.width
for y=#buffer+1,height do
local row={}
for x=1,width do
row[x]={char=" ",textColor=fg,backgroundColor=bg}
end
buffer[y]=row
end
end
buffer.width=width
buffer.height=height
end
end,
blit=
function(buffer,sx,sy,dx, dy, width,height)
sx=sx or 1
sy=sy or 1
dx=dx or buffer.scrX
dy=dy or buffer.scrY
width=width or buffer.width
height=height or buffer.height
local h=sy+height>buffer.height and buffer.height-sy or height-1
for y=0,h do
local row=buffer[sy+y]
local x=0
local cell=row[sx]
local fg,bg=cell.textColor,cell.backgroundColor
local str=""
local tx=x
while true do
str=str..cell.char
x=x+1
if x==width or sx+x>buffer.width then
break
end
cell=row[sx+x]
if cell.textColor~=fg or cell.backgroundColor~=bg then
--write
term.setCursorPos(dx+tx,dy+y)
term.setTextColor(fg)
term.setBackgroundColor(bg)
term.write(str)
str=""
tx=x
fg=cell.textColor
bg=cell.backgroundColor
end
end
term.setCursorPos(dx+tx,dy+y)
term.setTextColor(fg)
term.setBackgroundColor(bg)
term.write(str)
end
end,
drawDirty =
function(buffer)
term.redirect(term.native)
for y=1,buffer.height do
if buffer[y].isDirty then
term.redirect(term.native)
buffer.blit(1,y,buffer.scrX,buffer.scrY+y-1,buffer.width,buffer.height)
term.restore()
buffer[y].isDirty=false
end
end
term.restore()
end,
makeActive =
function(buffer,posX, posY)
posX=posX or 1
posY=posY or 1
buffer.scrX=posX
buffer.scrY=posY
term.redirect(term.native)
buffer.blit(1,1,posX,posY,buffer.width,buffer.height)
term.setCursorPos(buffer.curX,buffer.curY)
term.setCursorBlink(buffer.cursorBlink)
term.setTextColor(buffer.textColor)
term.setBackgroundColor(buffer.backgroundColor)
buffer.isActive=true
term.restore()
end,
isBuffer = true,
}
function createRedirectBuffer(width,height,fg,bg,isColor)
bg=bg or colors.black
fg=fg or colors.white
isColor=isColor~=nil and isColor or term.isColor()
local buffer={}
do
local w,h=term.getSize()
width,height=width or w,height or h
end
for y=1,height do
local row={}
for x=1,width do
row[x]={char=" ",textColor=fg,backgroundColor=bg}
end
buffer[y]=row
end
buffer.scrX=1
buffer.scrY=1
buffer.width=width
buffer.height=height
buffer.cursorBlink=false
buffer.textColor=fg
buffer.backgroundColor=bg
buffer._isColor=isColor
buffer.curX=1
buffer.curY=1
local meta={}
local function wrap(f,o)
return function(...)
return f(o,...)
end
end
for k,v in pairs(redirectBufferBase) do
if type(v)=="function" then
meta[k]=wrap(v,buffer)
else
meta[k]=v
end
end
setmetatable(buffer,{__index=meta})
return buffer
end
local w,h = term.getSize()
local buff = createRedirectBuffer(w,h,colors.white,colors.black,true)
term.redirect(buff)
buff.makeActive(1,1)
function screenshot()
local function c(num) --color conversion
return string.format("%x",math.log(num)/math.log(2))
end
local text = ""
local fore = ""
local back = ""
for y,row in ipairs(buff) do
for x,char in ipairs(row) do
text=text..char.char
fore=fore..c(char.textColor)
back=back..c(char.backgroundColor)
end
end
local file = io.open("screen.txt","a")
local url = "\nhttp://janvanrosmalen.com/ccrender/color/"
local function add(text)
url = url..textutils.urlEncode(tostring(text)).."/"
end
add(w) add(h) add(text) add(fore) add(back) add(buff.curX) add(buff.curY)
add(c(buff.textColor)) add(c(buff.backgroundColor)) add(buff.cursorBlink)
file:write(url.."screenshot.png")
file:close()
end
local roll=true
function go()
print("Press f1 to make a screenshot.")
print("Type exit to leave screenshot mode")
shell.run("rom/programs/shell")
roll=false
end
local route = coroutine.create(go)
os.queueEvent("derp")
while roll do
local evt = {os.pullEventRaw()}
if (evt[1]=="key") and (evt[2]==keys.f1) then
screenshot()
end
coroutine.resume(route,unpack(evt))
end
term.restore()
term.clear()
term.setCursorPos(1,1)
print("Left screenshot mode")
<?php
$mcwool = array();
$mcwool[0] = array(255,255,255); // White
$mcwool[1] = array(235,136,68); // Orange
$mcwool[2] = array(195,84,205); // Magenta
$mcwool[3] = array(102,137,211); // Light blue
$mcwool[4] = array(222,222,108); // Yellow
$mcwool[5] = array(65,205,52); // Lime
$mcwool[6] = array(216,129,152); // Pink
$mcwool[7] = array(67,67,67); // Gray
$mcwool[8] = array(153,153,153); // Light gray
$mcwool[9] = array(40,118,151); // Cyan
$mcwool[10] = array(123,47,190); // Purple
$mcwool[11] = array(37,49,146); // Blue
$mcwool[12] = array(81,48,26); // Brown
$mcwool[13] = array(59,81,26); // Green
$mcwool[14] = array(179,49,44); // Red
$mcwool[15] = array(0,0,0); // Black
function between($what,$l,$r){
$m = (int) $what;
if ($m<$l) {
return $l;
};
if ($m>$r) {
return $r;
};
return $m;
};
header("Content-type: image/png");
$width = between($_GET['w'],1,100);
$height = between($_GET['h'],1,100);
$string = $_GET['t'];
$fore = $_GET['f'];
$back = $_GET['b'];
$bbg = false;
if ($back==""){
$bbg=true;
};
$cx = between($_GET['x'],1,100);
$cy = between($_GET['y'],1,100);
$cfore = $_GET['m'];
$cback = $_GET['n'];
$im = imagecreatetruecolor($width*6+1, $height*9+1);
$getcol = array();
for ($i=0;$i<16;$i++) {
$getcol[$i] = imagecolorallocate($im,$mcwool[$i][0],$mcwool[$i][1],$mcwool[$i][2]);
};
for ($y=0;$y<$height;$y++){
for ($x=0;$x<$width;$x++){
if ($bbg==false){
imagefilledrectangle ($im,$x*6,$y*9,$x*6+6,$y*9+9, $getcol[(int) hexdec($back[$y*$width+$x])]);
};
$letter = (string) $string[$y*$width+$x];
$data = imageftbbox (6,0,"Minecraftia",$letter);
imagefttext($im,6,0,$x*6+(5-$data[2])/2,$y*9+7,$getcol[(int) hexdec($fore[$y*$width+$x])],"Minecraftia",$letter);
}
}
imagestring($im,3,1,1,(string) $cblink,$getcol[1]);
imagefilledrectangle ($im,$cx*6-6,$cy*9-2,$cx*6-2,$cy*9-2, $getcol[(int) hexdec($cfore)]);
imagepng($im);
imagedestroy($im);
?>
Options +FollowSymlinks RewriteEngine on RewriteRule ^color/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+).png screenshot.php?w=$1&h=$2&t=$3&f=$4&b=$5&x=$6&y=$7&m=$8&n=$9 [NC] RewriteRule ^trick/([^/]+)/([^/]+)/([^/]+).png screenshot.php?w=$1&h=$2&t=$3 [NC] DirectoryIndex screenshot.php
Posted by
Jan
on 03 May 2013 - 04:28 PM
in
Suggestions
Bubba, on 24 April 2013 - 12:12 PM, said:
Posted by
Jan
on 03 May 2013 - 03:48 PM
in
Suggestions
Posted by
Jan
on 20 March 2013 - 04:57 AM
in
General
Shnupbups100, on 18 March 2013 - 10:00 AM, said:
Lyqyd, on 19 March 2013 - 02:37 AM, said:
Posted by
Jan
on 17 March 2013 - 08:55 AM
in
General
local time = 0
local text = ""
local state = {}
local timestep = 0
-- State
local function resetstate()
state.dooropen = false
state.sitting = false
state.pantsoff = false
state.timestep = 0
end
resetstate()
-- Writing stuff
local function readit(cmax)
local x,y = term.getCursorPos()
local width = term.getSize()
local max = cmax or (width-2)
term.setCursorBlink(true)
local function disp()
term.clearLine()
term.setCursorPos(1,y)
write(">") write(" "..text)
term.setCursorPos(2+#text+1,y)
end
disp()
while true do
local a,b = os.pullEvent()
if a=="char" and #text<max then
text = text..b
disp()
elseif a=="key" then
if b==keys.enter then
print()
term.setCursorBlink(false)
local ok = text
text = ""
return ok
elseif b==keys.backspace then
text=text:sub(1,#text-1)
disp()
end
elseif a=="timer" and b==time then
term.clearLine()
term.setCursorPos(1,y)
term.setCursorBlink(false)
return text,true
end
end
end
function printf(text)
writef(text)
print("")
end
function writef(text)
term.setBackgroundColor(1)
term.setTextColor(2^15)
write(text)
term.setBackgroundColor(2^15)
term.setTextColor(1)
end
-- Game commands
local infos ={}
local syno = {}
-- Looking around
function infos.status()
local mes = ""
if state.sitting then
mes = mes .. "You are sitting on the toilet"
if state.pantsoff then
mes = mes .. " with your pants off"
end
else
mes = mes .. "You are standing in a hall"
if state.pantsoff then
mes = mes .. " with your pants off"
end
mes = mes .. ". There is a wooden door"
if state.dooropen then
mes = mes .. ", it is open. There is a toilet behind the door"
end
end
print(mes..".")
end
syno.status = {"look","watch","see","lookaround","examine","examineroom","examinehall"}
-- Pushing the door (also open)
function infos.pushdoor()
if state.sitting then
print("You can't reach the door because you are sitting.")
else
if state.dooropen then
print("You closed the door. Why would you that anyway?")
state.dooropen=false
else
write("You tried ")
writef("pushing")
write(" the door but it won't open.")
print("")
end
end
end
syno.pushdoor = {"push","open","opendoor"}
function infos.pulldoor()
if state.sitting then
print("You can't reach the door because you are sitting.")
else
if state.dooropen then
print("You are pulling with all your strength, and suddenly you realize the door is already open.")
else
print("You opened the door. There is a toilet behind the door. (what a suprise!)")
state.dooropen=true
end
end
end
syno.pulldoor = {"pull"}
function infos.sit()
print("Sit on what?")
text = "sit on "
end
syno.sit = {"sitdown"}
function infos.sittoilet()
if state.sitting then
print("You are already sitting.")
else
if state.dooropen then
print("You are sitting on the toilet.")
state.sitting = true
else
print("I don't see any toilet here.")
end
end
end
syno.sittoilet = {"sitontoilet"}
function infos.stand()
if state.sitting then
print("You are now standing in the hall.")
state.sitting = false
else
print("You are already standing.")
end
end
syno.stand = {"standup","goofftoilet"}
function infos.pantsoff()
if state.sitting then
print("You can't do that while you are sitting.")
else
if state.pantsoff then
print("Your pants are already off. Put them on if you really want to put them off again.")
else
print("You put your pants off.")
state.pantsoff=true
end
end
end
syno.pantsoff = {"putpantsoff","putoffpants"}
function infos.pantson()
if state.sitting then
print("You can't do that while you are sitting.")
else
if state.pantsoff then
print("Your put your pants back on. May I ask why?")
state.pantsoff=false
else
print("You are already wearing your pants.")
end
end
end
syno.pantson = {"putpantson","putonpants"}
function infos.pants()
print("Pants are awesome, aren't they?")
end
function infos.shit()
state.timestep = 2
time = os.startTimer(0.2)
end
function infos.help()
print("Help who?")
text = "help "
end
infos["help me"] = function()
print("Hmmm... Maybe you could try looking around?")
end
-- Saving syno's
for mainword,others in pairs(syno) do
for n,other in ipairs(others) do
infos[other] = infos[mainword]
end
end
-- evil timing mechanism
local tmes = {"* Hurry! Don't shit your pants! 35 seconds left. *",
"* The pressure is getting higher! 10 seconds. *",
"* You are shitting ! *"}
local tsec = {25,10,}
-- Play function
function lose()
local timer = 0
print("Press enter to continue...")
readit(0)
print("")
if state.pantsoff then
if state.sitting then
printf(" You won! ")
print("Congratulations!")
else
print("Oh no.... you shit on the floor.")
print("But luckely you had your pants off! so...")
printf(" You won! ")
end
else
printf(" You lost!")
end
text=""
print("")
print("Press enter to continue...")
readit(0)
end
function play()
print("")
print("You really need to take a shit...")
printf("* You have 1 minute left. Good luck! *")
resetstate()
time = os.startTimer(2500)
print("You are in a hall.")
while true do
ori,b = readit()
a = ori:gsub(" a ",""):gsub("the",""):gsub("( )","")
if b==true then
state.timestep=state.timestep+1
if state.timestep==3 then
printf(tmes[state.timestep])
lose()
break
end
printf(tmes[state.timestep])
time = os.startTimer(tsec[state.timestep])
else
local func = infos[a]
if func then
func()
else
print("I don't know how to "..ori)
end
end
end
end
-- Main loop
while true do
print()
printf(" Don't Shit Your Pants! ")
print(" A survivor horror game.")
print("")
print([[Instructions:
- To start type "play".
- To view achievements type "awards".
Goal:
- Don't shit your pants.
]])
while true do
local a = readit()
if a=="exit" or a=="quit" then
return
elseif a=="play" then
play()
break
else
print("Unknown command")
end
end
end
Posted by
Jan
on 17 March 2013 - 08:44 AM
in
APIs and Utilities
Posted by
Jan
on 17 March 2013 - 04:03 AM
in
APIs and Utilities
GopherAtl, on 17 March 2013 - 03:00 AM, said:
Posted by
Jan
on 16 March 2013 - 11:23 PM
in
APIs and Utilities
Posted by
Jan
on 16 March 2013 - 11:00 PM
in
APIs and Utilities
GopherAtl, on 16 March 2013 - 07:59 AM, said:
Posted by
Jan
on 09 March 2013 - 10:36 PM
in
APIs and Utilities
ChrisJay, on 09 March 2013 - 12:29 PM, said:
Posted by
Jan
on 08 March 2013 - 07:22 AM
in
APIs and Utilities
Jan, on 05 March 2013 - 04:47 AM, said:
Posted by
Jan
on 05 March 2013 - 04:47 AM
in
APIs and Utilities
Posted by
Jan
on 28 February 2013 - 05:29 AM
in
Suggestions
