Search Results

Search found 79 results on 4 pages for 'tetris'.

Page 1/4 | 1 2 3 4  | Next Page >

  • Pumpktris: The Tetris-Enabled Jack-o’-Lantern [Video]

    - by Jason Fitzpatrick
    You can carve a pumpkin, you might even go high-tech and wire it up with a few LEDs, but can you play Tetris on it? Check out this fully functional Tetris clone built into a jack-o’-lantern. The build comes to us courtesy of tinker Nathan at HaHaBird, who writes: One of my habits is to write down all the crazy, fleeting ideas I have, then go back to review later rather than judging right off the bat, or even worse, forgetting them. Earlier in the month I was looking through that idea notepad and found “Make Tetris Pumpkins” from sometime last year. My original plan had been to make forms to shape pumpkins into Tetris pieces as they grew, then stack them together for Halloween. Since Halloween was only a few weeks away and it was too late to start growing pumpkins, I thought “Why not make a pumpkin you can play Tetris on instead?” Watch the Pumpktris in action via the video above or hit up the link below to see exactly how he went about building it. Pumpktris [via Geek News Central] 6 Start Menu Replacements for Windows 8 What Is the Purpose of the “Do Not Cover This Hole” Hole on Hard Drives? How To Log Into The Desktop, Add a Start Menu, and Disable Hot Corners in Windows 8

    Read the article

  • Tetris Piece Rotation Algorithm

    - by coppercoder
    What are the best algorithms (and explanations) for representing and rotating the pieces of a tetris game? I always find the piece rotation and representation schemes confusing. Most tetris games seem to use a naive "remake the array of blocks" at each rotation: http://www.codeplex.com/Project/ProjectDirectory.aspx?ProjectSearchText=tetris However, some use pre-built encoded numbers and bit shifting to represent each piece: http://www.codeplex.com/wintris Is there a method to do this using mathematics (not sure that would work on a cell based board)?

    Read the article

  • How to write Tetris in Scala? (code review)

    - by eed3si9n
    Today's the 25th birthday of Tetris. I believe writing Tetris clone is one of the best ways to familiarize oneself to a new language or a platform. It's not completely trivial and it lends itself well to learning language specific constructs like iterators and closures. I've been hearing about Scala, and finally decided to read some docs and write a Tetris clone. So, this is my first Scala code. I did try to use functional constructs, but am sure there are lots of things I can improve to do it more Scala way. Please give me suggestions using comment. Also other submissions of Tetris clone in Scala are welcome too. I'm aware that the actual question itself is somewhat subjective, but I think this is of some value since others can use this as example (or anti-example) code. Edit: Let me rephrase the question. What can I do to make the code more Scala-ish?

    Read the article

  • Friday Fun: Play Tetris in Google Chrome

    - by Asian Angel
    Do you prefer playing classic games rather than the newer ones? Then get ready for some classic goodness with the JC-Tetris extension for Google Chrome. JC-Tetris in Action When you click on your new “JC-Tetris Toolbar Button” a new mini-Chrome window will open with the game displayed inside. This could be very convenient for those who would like or need to pause the game, minimize the window, and finish the game later. All that is needed to play are the four “Arrow Keys & the Space Bar”. Note: The text was small when the window first opened during our test so we used the “Ctrl +” keyboard shortcut twice to enlarge it. You may or may not experience similar text size results. Like any Tetris game things start out “quietly enough” but this one speeds up quickly, so be prepared! Notice that you do get a warning of what is waiting to drop onto the game board on the left side. Whenever you complete a game you will see this small window asking if you would like to enter a name for the score…you can easily ignore/bypass the window by clicking “Cancel”. Another game and a much better result. Do not be surprised if you feel that little burst of “rushed panic” at the end! Conclusion JC-Tetris is an enjoyable way to relax when you need a break. The ability to pause the game and minimize it for later makes it even better. Have fun! Links Download the JC-Tetris extension (Google Chrome Extensions) Similar Articles Productive Geek Tips Friday Fun: Get Your Mario OnFriday Fun: First Person TetrisFriday Fun: Play MineSweeper in Google ChromeFriday Fun: Play 3D Rally Racing in Google ChromeHow to Make Google Chrome Your Default Browser TouchFreeze Alternative in AutoHotkey The Icy Undertow Desktop Windows Home Server – Backup to LAN The Clear & Clean Desktop Use This Bookmarklet to Easily Get Albums Use AutoHotkey to Assign a Hotkey to a Specific Window Latest Software Reviews Tinyhacker Random Tips DVDFab 6 Revo Uninstaller Pro Registry Mechanic 9 for Windows PC Tools Internet Security Suite 2010 Dark Side of the Moon (8-bit) Norwegian Life If Web Browsers Were Modes of Transportation Google Translate (for animals) Out of 100 Tweeters Roadkill’s Scan Port scans for open ports

    Read the article

  • tetris rotation

    - by Samuel
    Hey, For university we're supposed to write a game (the language is modula2 little chance you know it). Each tetromino is defined through a central piece and 3 relative pieces, Now when it comes to rotation i just rotate the relative blocks (linear algebra). What i am asking myself is how to handle the rotations a user does when the piece has already "landed" because than the user has a little time left to move his pieve quickly into the desired position but in tetris versions all over the web you can "rotate over" other pieces, but i dont seem to get it with my rotation. Over what piece do i need to rotate? are there guidelines? Thanks

    Read the article

  • Problem setting output flags for ALU in "Nand to Tetris" course

    - by MahlerFive
    Although I tagged this homework, it is actually for a course which I am doing on my own for free. Anyway, the course is called "From Nand to Tetris" and I'm hoping someone here has seen or taken the course so I can get some help. I am at the stage where I am building the ALU with the supplied hdl language. My problem is that I can't get my chip to compile properly. I am getting errors when I try to set the output flags for the ALU. I believe the problem is that I can't subscript any intermediate variable, since when I just try setting the flags to true or false based on some random variable (say an input flag), I do not get the errors. I know the problem is not with the chips I am trying to use since I am using all builtin chips. Here is my ALU chip so far: /** * The ALU. Computes a pre-defined set of functions out = f(x,y) * where x and y are two 16-bit inputs. The function f is selected * by a set of 6 control bits denoted zx, nx, zy, ny, f, no. * The ALU operation can be described using the following pseudocode: * if zx=1 set x = 0 // 16-bit zero constant * if nx=1 set x = !x // Bit-wise negation * if zy=1 set y = 0 // 16-bit zero constant * if ny=1 set y = !y // Bit-wise negation * if f=1 set out = x + y // Integer 2's complement addition * else set out = x & y // Bit-wise And * if no=1 set out = !out // Bit-wise negation * * In addition to computing out, the ALU computes two 1-bit outputs: * if out=0 set zr = 1 else zr = 0 // 16-bit equality comparison * if out<0 set ng = 1 else ng = 0 // 2's complement comparison */ CHIP ALU { IN // 16-bit inputs: x[16], y[16], // Control bits: zx, // Zero the x input nx, // Negate the x input zy, // Zero the y input ny, // Negate the y input f, // Function code: 1 for add, 0 for and no; // Negate the out output OUT // 16-bit output out[16], // ALU output flags zr, // 1 if out=0, 0 otherwise ng; // 1 if out<0, 0 otherwise PARTS: // Zero the x input Mux16( a=x, b=false, sel=zx, out=x2 ); // Zero the y input Mux16( a=y, b=false, sel=zy, out=y2 ); // Negate the x input Not16( in=x, out=notx ); Mux16( a=x, b=notx, sel=nx, out=x3 ); // Negate the y input Not16( in=y, out=noty ); Mux16( a=y, b=noty, sel=ny, out=y3 ); // Perform f Add16( a=x3, b=y3, out=addout ); And16( a=x3, b=y3, out=andout ); Mux16( a=andout, b=addout, sel=f, out=preout ); // Negate the output Not16( in=preout, out=notpreout ); Mux16( a=preout, b=notpreout, sel=no, out=out ); // zr flag Or8way( in=out[0..7], out=zr1 ); // PROBLEM SHOWS UP HERE Or8way( in=out[8..15], out=zr2 ); Or( a=zr1, b=zr2, out=zr ); // ng flag Not( in=out[15], out=ng ); } So the problem shows up when I am trying to send a subscripted version of 'out' to the Or8Way chip. I've tried using a different variable than 'out', but with the same problem. Then I read that you are not able to subscript intermediate variables. I thought maybe if I sent the intermediate variable to some other chip, and that chip subscripted it, it would solve the problem, but it has the same error. Unfortunately I just can't think of a way to set the zr and ng flags without subscripting some intermediate variable, so I'm really stuck! Just so you know, if I replace the problematic lines with the following, it will compile (but not give the right results since I'm just using some random input): // zr flag Not( in=zx, out=zr ); // ng flag Not( in=zx, out=ng ); Anyone have any ideas? Edit: Here is the appendix of the book for the course which specifies how the hdl works. Specifically look at section 5 which talks about buses and says: "An internal pin (like v above) may not be subscripted". Edit: Here is the exact error I get: "Line 68, Can't connect gate's output pin to part". The error message is sort of confusing though, since that does not seem to be the actual problem. If I just replace "Or8way( in=out[0..7], out=zr1 );" with "Or8way( in=false, out=zr1 );" it will not generate this error, which is what lead me to look up in the appendix and find that the out variable, since it was derived as intermediate, could not be subscripted.

    Read the article

  • Tetris Movement - Implementation

    - by James Brauman
    Hi gamedev, I'm developing a Tetris clone and working on the input at the moment. When I was prototyping, movement was triggered by releasing a directional key. However, in most Tetris games I've played the movement is a bit more complex. When a directional key is pressed, the shape moves one space in that direction. After a short interval, if the key is still held down, the shape starts moving in the direction continuously until the key is released. In the case of the down key being pressed, there is no pause between the initial movement and the subsequent continuous movement. I've come up with a solution, and it works well, but it's totally over-engineered. Hey, at least I can recognize when things are getting silly, right? :) public class TetrisMover { List registeredKeys; Dictionary continuousPressedTime; Dictionary totalPressedTime; Dictionary initialIntervals; Dictionary continousIntervals; Dictionary keyActions; Dictionary initialActionDone; KeyboardState currentKeyboardState; public TetrisMover() { *snip* } public void Update(GameTime gameTime) { currentKeyboardState = Keyboard.GetState(); foreach (Keys currentKey in registeredKeys) { if (currentKeyboardState.IsKeyUp(currentKey)) { continuousPressedTime[currentKey] = TimeSpan.Zero; totalPressedTime[currentKey] = TimeSpan.Zero; initialActionDone[currentKey] = false; } else { if (initialActionDone[currentKey] == false) { keyActions[currentKey](); initialActionDone[currentKey] = true; } totalPressedTime[currentKey] += gameTime.ElapsedGameTime; if (totalPressedTime[currentKey] = initialIntervals[currentKey]) { continuousPressedTime[currentKey] += gameTime.ElapsedGameTime; if (continuousPressedTime[currentKey] = continousIntervals[currentKey]) { keyActions[currentKey](); continuousPressedTime[currentKey] = TimeSpan.Zero; } } } } } public void RegisterKey(Keys key, TimeSpan initialInterval, TimeSpan continuousInterval, Action keyAction) { if (registeredKeys.Contains(key)) throw new InvalidOperationException( string.Format("The key %s is already registered.", key)); registeredKeys.Add(key); continuousPressedTime.Add(key, TimeSpan.Zero); totalPressedTime.Add(key, TimeSpan.Zero); initialIntervals.Add(key, initialInterval); continousIntervals.Add(key, continuousInterval); keyActions.Add(key, keyAction); initialActionDone.Add(key, false); } public void UnregisterKey(Keys key) { *snip* } } I'm updating it every frame, and this is how I'm registering keys for movement: tetrisMover.RegisterKey( Keys.Left, keyHoldStartSpecialInterval, keyHoldMovementInterval, () = { Move(Direction.Left); }); tetrisMover.RegisterKey( Keys.Right, keyHoldStartSpecialInterval, keyHoldMovementInterval, () = { Move(Direction.Right); }); tetrisMover.RegisterKey( Keys.Down, TimeSpan.Zero, keyHoldMovementInterval, () = { PerformGravity(); }); Issues that this doesn't address: If both left and right are held down, the shape moves back and forth really quick. If a directional key is held down and the turn finishes and the shape is replaced by a new one, the new one will move quickly in that direction instead of the little pause it is supposed to have. I could fix the issues, but I think it will make the solution even worse. How would you implement this?

    Read the article

  • How do I create Tetris Blocks in XNA with C#?

    - by Slateboard
    I'm making a Tetris Clone in C# with XNA, and I'm unsure of how to actually implement the blocks. I don't think that making the shapes as images will work (because parts are removed when lines are formed), so I Have blocks to make up the pieces like This. Unfortunately, I don't know how to actually define the blocks to make the pieces, nor do I know how to manipulate them to make them rotate, etc. Edit: I would also need assistance in learning how to make the Tetris Grid too.

    Read the article

  • Being a Team Lead is like playing Tetris

    - by thycotic
    Tucker has posted about his experiences as Team Lead on our product development team.  Team Leads are hands-on coders on our teams but they are also responsible for working with the ScrumMaster/ProductOwner to co-ordinate on the status and priority of tasks which is where the juggling begins. :) It takes good technical skills combined with people smarts and solid task management to move the entire team towards the end goal.   Jonathan Cogley is the CEO of Thycotic Software, an agile software services and product development company based in Washington DC.  Secret Server is our flagship enterprise password vault.

    Read the article

  • Tetris : Effective rotation

    - by hqt
    I rotate each piece by rotation formula. More detail, because rotation angle is 90 so : xNew = y; yNew = -x; But my method has met two problems : 1) Out of box : each type of pieces is fit in square 4x4. (0,0 at under left) But by this rotation, at some case they will out of this box. For example, there is a point with coordinate (5,6) So, please help me how to fit these coordinate into 4x4 box again, or give me another formula for this. 2) at I case : (4 squares at same row or same column), just has two rotations case. but in method above, they still has 4 pieces. So, how to prevent this. Thanks :)

    Read the article

  • Vectors or Java arrays for Tetris?

    - by StackedCrooked
    I'm trying to create a Tetris-like game with Clojure and I'm having some trouble deciding the data structure for the playing field. I want to define the playing field as a mutable grid. The individual blocks are also grids, but don't need to be mutable. My first attempt was to define a grid as a vector of vectors. For example an S-block looks like this: :s-block { :grids [ [ [ 0 1 1 ] [ 1 1 0 ] ] [ [ 1 0 ] [ 1 1 ] [ 0 1 ] ] ] } But that turns out to be rather tricky for simple things like iterating and painting (see the code below). For making the grid mutable my initial idea was to make each row a reference. But then I couldn't really figure out how to change the value of a specific cell in a row. One option would have been to create each individual cell a ref instead of each row. But that feels like an unclean approach. I'm considering using Java arrays now. Clojure's aget and aset functions will probably turn out to be much simpler. However before digging myself in a deeper mess I want to ask ideas/insights. How would you recommend implementing a mutable 2d grid? Feel free to share alternative approaches as well. Source code current state: Tetris.clj (rev452)

    Read the article

  • How do i pack multiple rectangles in a 2d box tetris style

    - by mglmnc
    I have a number of rectangles of various widths and heights. I have a larger rectangular platform to put them on. I want to pack them on one side of the platform so they spread in the lengthwise (X) dimension but keep the widthwise (Y) dimension to a minimal. That is to place them like a tetris game. There can be no overlaps but there can be gaps. Is there an algorithm out there to do this?

    Read the article

  • Splitting a tetris game apart - where to put time-management?

    - by nightcracker
    I am creating a tetris game in C++ & SDL, and I'm trying to do it "good" by making it object-oriented and keeping scopes small. So far I have the following structure: A main with some lowlevel SDL set up and handling input A game class that keeps track of score and provides the interface for main (move block down, etc) A map class that keeps track of the current game field, which blocks are where. Used by the game class. A block class that consists of the current falling block, used by game. A renderer class abstracting low level SDL to a format where you render "tetris blocks". Used by map and block. Now I have a though time where to place the time-management of this game. For example, where should be decided when a block bumps the bottom of the screen how long it takes the current block locks in place and a new block spawns? I also have an other unrelated question, is there some place where you can find some standard data on tetris like standard score tables, rulesets, timings, etc?

    Read the article

  • Splitting a tetris game apart - where to put time-management?

    - by nightcracker
    I am creating a tetris game in C++ & SDL, and I'm trying to do it "good" by making it object-oriented and keeping scopes small. So far I have the following structure: A main with some lowlevel SDL set up and handling input A game class that keeps track of score and provides the interface for main (move block down, etc) A map class that keeps track of the current game field, which blocks are where. Used by the game class. A block class that consists of the current falling block, used by game. A renderer class abstracting low level SDL to a format where you render "tetris blocks". Used by map and block. Now I have a though time where to place the time-management of this game. For example, where should be decided when a block bumps the bottom of the screen how long it takes the current block locks in place and a new block spawns? I also have an other unrelated question, is there some place where you can find some standard data on tetris like standard score tables, rulesets, timings, etc?

    Read the article

  • python list Index out of range error

    - by dman762000
    I am working on a python tetris game that my proffessor assigned for the final project of a concepts of programming class. I have got just about everything he wanted to work on it at this point but I am having a slight problem with one part of it. Whenever I start moving pieces left and right I keep getting "index out of range error". This only happens when it is up against a piece. Here are the culprits that are giving me grief. def clearRight(block=None): global board, activeBlock, stackedBlocks isClear = True if(block == None): block = activeBlock if(block != None): for square in block['squares']: row = square[1] col = square[0]+1 if(col >= 0 and stackedBlocks[row][col] !=None): isClear=False return isClear def clearLeft(block=None): global board, activeBlock, stackedBlocks isClear = True if(block == None): block = activeBlock if(block != None): for square in block['squares']: row = square[1] col = square[0]-1 if(col >= 0 and stackedBlocks[row][col] !=None): isClear=False return isClear I am not looking to get anyone to fix it for me, I'm only looking for tips on how to fix it myself. Thanks in advance for any help that is given.

    Read the article

  • Null Pointer Exception on a 2D array (Java)

    - by user315156
    I have a class, "Tetris", in which one of the instance variables is "board". "board" is 2D array of Color objects. Upon the creation of a tetris object I call a method that sets the dimensions of board and then sets all of the Color objects to be the Default value, that is to say, Color.blue. public Tetris(int rows, int cols){ this.rows = rows; this.cols = cols; reset(rows, cols); } public void reset(int rows, int cols){ Color[][] board = new Color[rows][cols]; for(int i = 0; i Unfortunately, when I run the code (which obviously has not been posted in its entirety) I get a null pointer exception on the line: board[i][j] = DEFAULT_COLOR; // Color.blue; //DEFAULT-COLOR. Is there anything obviously wrong with what I am doing? (Sorry if there are glaring format issues, this is my first time on Stack Overflow)

    Read the article

  • copyright of some arcade classics [closed]

    - by kamziro
    Possible Duplicate: How closely can a game resemble another game without legal problems So suppose I'm currently developing a variant of a snakes game for the iPhone, and you decided to call it "snakes". First, in general, how would you find out if a name's been copyrighted or not? It's probably safe with "snakes" because it's such a common word, and that there's been so many games around (please correct me if I'm wrong), but with some people copyrighting the name "edge", it would be best to be a bit careful. Second, suppose I decided to go with some name that is guaranteed to be different (e.g EL SERPENTES DE LOS REYES), would gameplay be a point of contention on copyright issues? For example, the tetris game is sort of "copyrighted" at the apple app store, and there was a crackdown on anyone using the word "tris" or anything related to it. However, if there was a game with the gameplay of tetris (or loosely very similar), with the name "BLOXODEREX", can it be liable to copyright/DMCA issues?

    Read the article

  • Online Multiplayer Game Architecture [on hold]

    - by Eric
    I am just starting to research online multiplayer game development and I have a high-level architectural question regarding how online multiple games function. I have server-side and client-side programming experience, and I understand how AJAX-esque transfer protocol operates. What I don't understand yet is how online multiple fits into all of that. For example, an online Tetris multiplayer game. Would both players have the entire Tetris game built out on their client-side and then get pushed "moves" from the other player via some AJAX-esque mechanism, in which case each client would have to be constantly listening via JavaScript for inbound "moves" and update the client appropriately? Or would each client build out the aesthetics and run a virtual server per game to which each client connects and thus pull and push commands in real-time via something like web sockets? I apologize if this question is too high-level and general, but I couldn't find anything online that offered this high-level of a perspective on the topic.

    Read the article

  • Legality of similar games

    - by Jamie Taylor
    This is my first question on GD.SE, and I hope it's in the right place. A little background: I'm an amateur (read: not explicitly employed to develop games, but am employed as a software developer) game developer and took a ComSci with Games Development degree. My Question: What is the legal situation/standpoint of creating a copycat title? I know that there are only N number of ways of solving a problem, and N number of ways to design a piece of software. Say that an independent developer designed a copycat game (a Tetris clone in this example) for instance, and decided to use that game to generate income for themselves as well as interest for their other products. Say the developer adds a disclaimer into the software along the lines of "based on , originally released c. by ." Are there any legal problems/grey areas with the developer in this example releasing this game, commercially? Would they run into legal problems? Should the developer in this example expect cease and desist orders or law suit claims from original publishers? Have original publishers been known to, effectively, kill independent projects because they are a little too close to older titles? I know that there was, at least, one attempt by a group of independent developers to remake Sonic the Hedgehog 2 and Sega shut them down. I also know of Sega shutting down development of the independent Streets of Rage Remake. I know that "but it's an old game, your honour," isn't a great legal standpoint when it comes to defending yourself. But, could an independent developer have a law suit filed against them for re-implementing an older title in a new way? I know that there are a lot of copycat versions of the older titles like Tetris available on app stores (and similar services), and that it would be very difficult for a major publisher to shut them all down. Regardless of this, is making a Tetris (or other game) copycat/clone illegal? We were taught lots of different things at University, but we never covered copyright law. I'm presuming that their thought behind it was "IF these students get jobs in games development, they wont need to know anything about the legal side of it, because their employers will have legal departments... presumably" tl;dr Is it illegal to create a clone or copycat of an old title, and make money from it?

    Read the article

  • Designing generic render/graphics component in C++?

    - by s73v3r
    I'm trying to learn more about Component Entity systems. So I decided to write a Tetris clone. I'm using the "style" of component-entity system where the Entity is just a bag of Components, the Components are just data, a Node is a set of Components needed to accomplish something, and a System is a set of methods that operates on a Node. All of my components inherit from a basic IComponent interface. I'm trying to figure out how to design the Render/Graphics/Drawable Components. Originally, I was going to use SFML, and everything was going to be good. However, as this is an experimental system, I got the idea of being able to change out the render library at will. I thought that since the Rendering would be fairly componentized, this should be doable. However, I'm having problems figuring out how I would design a common Interface for the different types of Render Components. Should I be using C++ Template types? It seems that having the RenderComponent somehow return it's own mesh/sprite/whatever to the RenderSystem would be the simplest, but would be difficult to generalize. However, letting the RenderComponent just hold on to data about what it would render would make it hard to re-use this component for different renderable objects (background, falling piece, field of already fallen blocks, etc). I realize this is fairly over-engineered for a regular Tetris clone, but I'm trying to learn about component entity systems and making interchangeable components. It's just that rendering seems to be the hardest to split out for me.

    Read the article

  • Good implementations of reinforced learning?

    - by Paperino
    For an ai-class project I need to implement a reinforcement learning algorithm which beats a simple game of tetris. The game is written in Java and we have the source code. I know the basics of reinforcement learning theory but was wondering if anyone in the SO community had hands on experience with this type of thing. What would your recommended readings be for an implementation of reinforced learning in a tetris game? Are there any good open source projects that accomplish similar things that would be worth checking out? Thanks in advanced Edit: The more specific the better, but general resources about the subject are welcomed. Follow up: Thought it would be nice if I posted a followup. Here's the solution (code and writeup) I ended up with for any future students :). Paper / Code

    Read the article

1 2 3 4  | Next Page >