people playing: 80, servers online: 25, games played: 142,112,865 Top Player: McFarbo

 Toribash Community » Mods Random useless (or not) mini-scripts thread
 User Name Remember Me? Password
 Register FAQ General Rules Community
 Thread Tools Display Modes
 Dec 24, 2012 #11 Yoyo   5th Dan Black Belt Join Date: Nov 2009 Posts: 4,243 Clan: Creamy Horse Mouths I want mine to look more like this. multiple texture uploader! updated: multiple texture remover! updated pretty colorlist! ok ive just rebooted my pc and ive tried to activate my reflex on yahoo internet explorer :/ no luck I do not enjoy having anal sex with multiple men
 Dec 25, 2012 #12 psycore Member   2nd Dan Black Belt Join Date: Feb 2010 Posts: 388 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: Code: 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. Signature temporarily out of order. Last edited by Thrandir; Aug 25, 2015 at 07:51 PM..
 Dec 25, 2012 #13 Yoyo   5th Dan Black Belt Join Date: Nov 2009 Posts: 4,243 Clan: Creamy Horse Mouths 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! ok ive just rebooted my pc and ive tried to activate my reflex on yahoo internet explorer :/ no luck I do not enjoy having anal sex with multiple men
 Jun 14, 2013 #14 box ?crazykid700=flashglass   Cardboard Belt Join Date: Sep 2007 Posts: 9,247 Clan: I am Code: 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] Blue eyes ultimate dragon best card [23:24:29] You know the one with 3 heads [23:24:39] <~Lightningkid> just like my dick [11:35:40] Hampa suck [11:36:21] not the first to tell me that today
 Jun 15, 2013 #15 ♥Blam Now I know my abc's!This user title is the property of SkulFuk.   4th Dan Black Belt Join Date: Apr 2007 Posts: 5,510 Clan: bncy You can click on people to get their names pop up, no? :P :D
 Jun 15, 2013 #16 box ?crazykid700=flashglass   Cardboard Belt Join Date: Sep 2007 Posts: 9,247 Clan: I am Well, yeah, but not in versions before like, 3.94... I'm sure someone will find it helpful! [23:23:53] Blue eyes ultimate dragon best card [23:24:29] You know the one with 3 heads [23:24:39] <~Lightningkid> just like my dick [11:35:40] Hampa suck [11:36:21] not the first to tell me that today
Jun 15, 2013   #17
Eleeleth
Also Only responds to 'Eleeth'!

6th Dan Black Belt
Join Date: Apr 2008
Posts: 1,577
Clan: NO

 Originally Posted by Blam You can click on people to get their names pop up, no? :P

:effort:
<~suomynona> TITS OR ELEELETH

 Jun 20, 2013 #18 ♥Blam Now I know my abc's!This user title is the property of SkulFuk.   4th Dan Black Belt Join Date: Apr 2007 Posts: 5,510 Clan: bncy :D
 May 15, 2015 #19 Merc NON-EXISTING!   8th Dan Black Belt Join Date: Feb 2013 Posts: 5,046 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
 Aug 23, 2015 #20 Stupinator Raconteur   6th Dan Black Belt Join Date: Mar 2008 Posts: 3,801 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) `````` Item Forger Last edited by Stupinator; Aug 23, 2015 at 09:08 AM..

 Posting Rules You may not post new threads You may not post replies You may not post attachments You may not edit your posts BB code is On Smilies are On [IMG] code is On HTML code is Off Forum Rules
 Forum Jump User Control Panel Private Messages Subscriptions Who's Online Search Forums Forums Home Toribash     News     Replays         Multiplayer Replays         Book of Records     Mods         Lua scripts         God Team         Third party     Events     Art     Suggestions & Ideas Help     Beginner Sanctuary         Introduce yourself     Technical Support         Beta Releases     FAQ     Tutorials Market     Art/Textures         Requests     Items         Particle Flames Clans     Organiζations         Official Organiζations             The Aikido Team                 The Aikido Council             Anime United                 Hentai HQ             Brazilian Toribash Organization                 BTO in a Box             GATA                 GATA Chambers             Indonizer                 Gedung DPR             New Order of Taekkyon                 Tk HQ             Official FRench Organization                 La Baguette             OLDA                 The OLDA Room             ORMO                 Precise focal precision             OSHI                 Chest of Wonders             #Polska                 Jama terroru             Portugal                 O Cantinho             RMO                 Leaders Nest             Toribash Academy                 Teachers' Room             Toribash по-русски                 Энциклопедия             Toribash Marketeers Organization                 Marketing perfected             Toribash Media                 The Crew             Toribash Tricktionary                 The Tricktionary Council     Clan Discussion         Official Clans             Adventure                 The Campfire             Aeon                 Aeon Politbuero             Alpha                 Sanctum             Creamy Horse Mouths                 Confederacy of Intergalactic Domination             Damned                 Dark Temple             Desolate             Don't Kill My Vibe                 Vibe's sex shop             Duck             Elite                 seekrit business             Evil                 BIG THINGS             Evolution                 eVo seekrit             fl0w                 ʍ0lɟ             Hack                 Rukeepers             Hidden                 The Root             Liquor                 Bar Storage             Midnight             Obey                 a fantastic lack-of-joboman's-posts appreciation board             Parrot                 Private-stuff             re                 re|dacted             RelaxAll                 RASA             Saint                 Black Market             Suki             Team Girl Scouts                 Yogi Oki-Doki's Farm             The Last Legion                 TLL             Traps Are Not Gay             Tribe                 Private Board             Undead             USSR                 USSR Secret             Vector             WAPOW         Recruitment Center General     Discussion     Off-Topic         Gaming Chat         Computer/Mobile Chat         Music/Movie Chat     Rapid Threads elerk     Tori Legends

All times are GMT +1. The time now is 04:03 AM.