Tori-Santa 2019


I want mine to look more like this.
multiple texture uploader! updated: multiple texture remover!
updated pretty colorlist!

<BobJoelZ> ok ive just rebooted my pc and ive tried to activate my reflex on yahoo internet explorer :/ no luck

<Aracoon> I do not enjoy having anal sex with multiple men
Ah I guess I know what you mean.
I think I know the problem but I don't really know how to describe it. I'll try it like this:
The walls aren't actually parts of the grid.
There are two types of cells:

Path-cells which either are or aren't part of the maze (yet). (When the algorithm is done, ALL path-cells will be part of the maze)

and

Wall-cells which can either be walls or passages.

Let's use colors for more explanation:

White: Path-cells which are part of the maze.
Grey: Path-cells which are not part of the maze yet.
Black: Walls
Green: Passages
Red: Potential passages
Pink: Chosen wall (see later)

The algorithm we're following is this:
1. Start with all wall-cells as walls and all path cells as not part of the maze.
2. Choose one path-cell. Make it part of the maze. Add neighboring walls to your wall queue (what you called "n". btw: seriously, choose better variable names. Mine aren't perfect either, but at least you get an idea what they're used for).
3. While the wall queue is not empty:
    3.a. Choose random element of the wall queue. (The one I painted pink)
    3.b. If only one path-cell at the selected queue element is part of the maze:
        3.b.1 Make the selected queue entry a passage.
        3.b.2 Add other path-cell to the maze.
        3.b.3 Add neighboring walls to the wall queue (if not already in there)

    3.c Remove selected queue entry from the queue.
4. Done
In pictures:

Initial state:

Image was removed.

Choose random queue element:

Image was removed.

3.b.1 - 3.c.:

Image was removed.

Repeat again and again:

Image was removed.

Example where 3.b. is false:

Image was removed.

Image was removed.

Now just color paths and passages white, walls and path-cells which are not yet part of the maze black and the selected queue element red and it'll look like the video:

Image was removed.
(Well, not very impressive, but I only have paint at the moment. Sorry )

I hope you get what I mean.
Last edited by Thrandir; Aug 25, 2015 at 07:51 PM.
Signature temporarily out of order.
I'm gonna try to absorb all you just said and redo the algorithm, thanks!
multiple texture uploader! updated: multiple texture remover!
updated pretty colorlist!

<BobJoelZ> ok ive just rebooted my pc and ive tried to activate my reflex on yahoo internet explorer :/ no luck

<Aracoon> I do not enjoy having anal sex with multiple men
size_x, size_y, size_z = 0.3, 0.3, 0.3

local function draw_box()
        set_color(1, 0, 0, .5)
		body = get_body_info(0, 11)
        draw_box_m(body.pos.x, body.pos.y, body.pos.z, size_x, size_y, size_z, body.rot)
		body = get_body_info(0, 12)
        draw_box_m(body.pos.x, body.pos.y, body.pos.z, size_x, size_y, size_z, body.rot)
        set_color(0, 0, 1, .5)
        body = get_body_info(1, 11)
        draw_box_m(body.pos.x, body.pos.y, body.pos.z, size_x, size_y, size_z, body.rot)
        body = get_body_info(1, 12)
        draw_box_m(body.pos.x, body.pos.y, body.pos.z, size_x, size_y, size_z, body.rot)
end

add_hook("draw3d", "draw_box", draw_box)
Extremely anti-complicated code that color-codes Tori and Uke's hands. You know, just in case you're in a room, and can't tell who is who. In those rare cases.

It's a thread for useless scripts, right?
[23:23:53] <AndChat|700625> Blue eyes ultimate dragon best card
[23:24:29] <AndChat|700625> You know the one with 3 heads
[23:24:39] <~Lightningkid> just like my dick



[11:35:40] <box> Hampa suck
[11:36:21] <hampa> not the first to tell me that today
You can click on people to get their names pop up, no? :P
:D
Well, yeah, but not in versions before like, 3.94...

I'm sure someone will find it helpful!
[23:23:53] <AndChat|700625> Blue eyes ultimate dragon best card
[23:24:29] <AndChat|700625> You know the one with 3 heads
[23:24:39] <~Lightningkid> just like my dick



[11:35:40] <box> Hampa suck
[11:36:21] <hampa> not the first to tell me that today
Originally Posted by Blam View Post
You can click on people to get their names pop up, no? :P

:effort:
<~suomynona> TITS OR ELEELETH
Can I post a vbs script too please? It's similar to Lua Coding. It's a Fake Prank Virus File If I can't post it here it's ok
So working on my sin and cos knowledge, I decided to just make a random script... and well... it's random alright.
lua code:
x = 0
y = 0
length = 50
angle = 0.0
angle_stepsize = .45
angtbl = {}
w,h = get_window_size()
lenset = 200

while angle < 2 * math.pi do

table.insert(angtbl,{x=lenset * math.cos(angle) + w/2, y=lenset *math.sin(angle) + h/2})

angle = angle + .1
end



add_hook("draw2d","y_test",function()

set_color(0,0,0,1)

draw_quad(0,0,w,h)
for i = 1,#angtbl do

set_color(math.random(),math.random(),math.random(),1)

draw_quad(angtbl[i].x, angtbl[i].y,4,4)
angtbl[i].x = angtbl[i].x + math.cos(math.random(0,360))*2
angtbl[i].y = angtbl[i].y + math.sin(math.random(0,360))*2

end
lenset = lenset + (150 - lenset/2)*.1

end)





also: this is good for random "explosion" particles:

lua code:
x = 0
y = 0
length = 50
angle = 0.0
angle_stepsize = .45
angtbl = {}
w,h = get_window_size()
lenset = 0
size = 4
oldtime = os.clock()

while angle < 2 * math.pi do

table.insert(angtbl,{x=lenset * math.cos(angle) + w/2, y=lenset *math.sin(angle) + h/2, dirx = math.cos(angle), diry = math.sin(angle)})
angle = angle + math.random()*2
end



add_hook("draw2d","y_test",function()
set_color(0,0,0,1)
draw_quad(0,0,w,h)
for i = 1,#angtbl do

set_color(math.random(),math.random(),math.random(),1)

draw_quad(angtbl[i].x, angtbl[i].y,size,size)
angtbl[i].x = angtbl[i].x + angtbl[i].dirx*4
angtbl[i].y = angtbl[i].y + angtbl[i].diry*4
if(size <= 0.01)then
table.remove(angtbl,i)
end
end
newtime = os.clock()
if(newtime > oldtime + .1)then
size = size - 1
oldtime = os.clock()
end

end)




aaaaand I added gravity because why not.

lua code:
x = 0
y = 0
length = 50
angle = 0.0
angle_stepsize = .45
angtbl = {}
w,h = get_window_size()
lenset = 0
size = 4
clicked = true
cursorx = 0
cursory = 0
gravity = 50





add_hook("draw2d","y_test",function()
set_color(0,0,0,1)
draw_quad(0,0,w,h)
if(clicked)then
while angle < 2 * math.pi do
table.insert(angtbl,{randgrey = math.random() * 2 - 2/2 + .5, gravity = 0, size = 7, x=lenset * math.cos(angle) + cursorx, y=lenset *math.sin(angle) + cursory, dirx = math.cos(angle), diry = math.sin(angle)})
angle = angle + math.random()*2
end
end
for i = 1,#angtbl do
set_color(math.random(),math.random(),math.random(),1)

draw_quad(angtbl[i].x, angtbl[i].y,angtbl[i].size,angtbl[i].size)
angtbl[i].size = angtbl[i].size + (0 - angtbl[i].size)*.05
angtbl[i].x = angtbl[i].x + angtbl[i].dirx*4
angtbl[i].y = (angtbl[i].y + angtbl[i].diry*4) + angtbl[i].gravity
angtbl[i].gravity = angtbl[i].gravity + (gravity - angtbl[i].gravity)*.005
if(angtbl[i].size <=0.01)then
table.remove(angtbl,i)
end
end

end)
function getmousepos(x,y)
cursorx = x
cursory = y
end
function mouseclicked(button,x,y)
clicked = true
cursorx = x
cursory = y
end
function mouseunclicked(button,x,y)
cursorx = x
cursory = y
angle = 0
end
add_hook("mouse_move","mousepos", getmousepos)
add_hook("mouse_button_down","mouseclicked",mouseclicked)
add_hook("mouse_button_up", "unclicked", mouseunclicked)
Last edited by Stupinator; Aug 23, 2015 at 09:08 AM.
Former Item Forger