• Announcements

    • khawk

      Download the Game Design and Indie Game Marketing Freebook   07/19/17

      GameDev.net and CRC Press have teamed up to bring a free ebook of content curated from top titles published by CRC Press. The freebook, Practices of Game Design & Indie Game Marketing, includes chapters from The Art of Game Design: A Book of Lenses, A Practical Guide to Indie Game Marketing, and An Architectural Approach to Level Design. The GameDev.net FreeBook is relevant to game designers, developers, and those interested in learning more about the challenges in game development. We know game development can be a tough discipline and business, so we picked several chapters from CRC Press titles that we thought would be of interest to you, the GameDev.net audience, in your journey to design, develop, and market your next game. The free ebook is available through CRC Press by clicking here. The Curated Books The Art of Game Design: A Book of Lenses, Second Edition, by Jesse Schell Presents 100+ sets of questions, or different lenses, for viewing a game’s design, encompassing diverse fields such as psychology, architecture, music, film, software engineering, theme park design, mathematics, anthropology, and more. Written by one of the world's top game designers, this book describes the deepest and most fundamental principles of game design, demonstrating how tactics used in board, card, and athletic games also work in video games. It provides practical instruction on creating world-class games that will be played again and again. View it here. A Practical Guide to Indie Game Marketing, by Joel Dreskin Marketing is an essential but too frequently overlooked or minimized component of the release plan for indie games. A Practical Guide to Indie Game Marketing provides you with the tools needed to build visibility and sell your indie games. With special focus on those developers with small budgets and limited staff and resources, this book is packed with tangible recommendations and techniques that you can put to use immediately. As a seasoned professional of the indie game arena, author Joel Dreskin gives you insight into practical, real-world experiences of marketing numerous successful games and also provides stories of the failures. View it here. An Architectural Approach to Level Design This is one of the first books to integrate architectural and spatial design theory with the field of level design. The book presents architectural techniques and theories for level designers to use in their own work. It connects architecture and level design in different ways that address the practical elements of how designers construct space and the experiential elements of how and why humans interact with this space. Throughout the text, readers learn skills for spatial layout, evoking emotion through gamespaces, and creating better levels through architectural theory. View it here. Learn more and download the ebook by clicking here. Did you know? GameDev.net and CRC Press also recently teamed up to bring GDNet+ Members up to a 20% discount on all CRC Press books. Learn more about this and other benefits here.


  • Content count

  • Joined

  • Last visited

Community Reputation

226 Neutral

About Deft

  • Rank
  1. [quote name='viper110110' timestamp='1347858569' post='4980783'] Welcome to C++, where the code's made up and the errors don't matter. Turns out my problem was forgetting MyClassName:: in front of the function, which was left out because I copied it out of the tutorial which had all the code in main.cpp. [/quote] If you don't know, what error matters, this is not mean that it's useless. Think you should try to understand how linker is working. If you've got unresolved symbol, then this means that you declared entity (such as method) and didn't implement it. Such error also could appear when you use library API without adding libraries themselves.
  2. I suggest that you can use the same formula: x += xVel * deltaTime. Why not to decrease x axis velocity value? Then you can set up real X position as x_real = (x / 20) * 20. This will gives you always 20x offset. Sorry, if I'm wrong. With regards.
  3. Collision detection in AS3 is done by call hitTestObject() function. That's all what you need. If you want check collisions for your object continuously - you can test collisions for each frame. To resolve collisions you need to use some simple mathematics with vectors. If you need to lock object movement when it's under wall (or floor, or ceiling), you need to check test collision and if it was found, prevent changing object coordinates. If you need to reflect object movement (as billiard balls, for example), you just need compute movement vector according to simple physics rule. These rules depends on your environment. In simple situation it will be just a ray reflection. Of course, its very primitive methods, if you need more realistic image, you need to know physics laws and formulas. But often for AS3 it's enough.
  4. [quote name='greenzone' timestamp='1347486742' post='4979482'] Both responses where very very helpful. in fact i have experienced this problem with I/O when trying to load geometry. the process of loading geometry hangs up the entire program and the more complex the geometry the longer the wait. So from what i understand threading would allow me to load geometry on the side of my program with out halting the main thread? I am assuming it would still take time but it would not stop one from continuing interaction with the main program being run by the main thread? [/quote] The thing is that with threads you've change processor timing. As known, processor (let's take single core CPU) can work with only one program at current time, CPU registers can be used only by one application. For example, DOS was single-application system, there you can run only one application simultaneously. Windows becomes the multi-task system, where you can launch few applications simultaneously. But processor is still one-application unit. The goal is that operating system distributes CPU time between few applications that you've ran. When you create additional thread at OS view point this is "sub-application" that can be executed separately from main application or another thread. Main problems during multi-threading programming are locks and concurrent data modifications. Lock appears when one thread needs some data, that can be provided only by another thread, but this thread is to busy and can't answer. So, first thread should do nothing or waiting while another thread will not answered. Concurrent data modification is situation when two or more threads tries change or use the same data. To resolve such problems, for example, in Java use synchronized methods and data. C++ has all these problems too. But another sense is that you really can distribute processor time and make your application much faster. You just should find those pieces of code, that can be separated and instantiated as thread.
  5. [quote]private BufferedImage image = new BufferedImage(WIDTH, HEIGHT,BufferedImage.TYPE_INT_RBG);[/quote] May be you mean TYPE_INT_RGB or TYPE_INT_BGR? BufferedImage does not have TYPE_INT_[b]RBG[/b] member.
  6. Sorry if I'm not right, but how you want to construct diamond with using squares? Square can give you cube or parallelepiped. In any case of building diamond you need additional triangle(s) for figure to be done. I suggest that you need to adopt your system to work with triangles and then build a diamond or any figure that you want. Sorry if I misunderstood your question. With regards.
  7. According to MSDN for DX9 CreatePixelShader: [quote] Return value Type: HRESULT If the method succeeds, the return value is D3D_OK. If the method fails, the return value can be one of the following: [b]D3DERR_INVALIDCALL, D3DERR_OUTOFVIDEOMEMORY, E_OUTOFMEMORY[/b].[/quote] Just make a switch statement for this variants of errors and look at case that will be invoked. After that point you can actually understand what is wrong with your pixel shader.
  8. Hey there)) Just relocate you base code into separated method. Making constructor big not so good. If you need to get re-usable code, wrap it with public method and call it wherever you want. This is true for singletons too.
  9. [quote name='JETerán' timestamp='1346369547' post='4974963'] URGENT: - Finish the inventory / store system so I can implement the inventory array in the GUI (Please help of EDIT 1 above) - Make the others hitTests for the rest of the in-game objects. Easy. - Make the hero look left when user hits left key. Tricky, I was some time doing this and couldn't figure out, tomorrow I will give it another try (later, actually) - Make the hero's animation (I have the animation in the MC, I just need to play() it the hero moves) URGENT: -Finish the game design, if player ends game, how to call again to call the MissionSelection function (I will work on what you told me Deft about it) [/quote] I don't know, was your problem with array push released or not, but anyway: I'd said a few posts later about that thing that Flash engine transfer variables (non-scalar types, such as custom objects) as links, and not as values. This is means that when you call addChild and use image1, you put some object on the scene. When you trying to add second object on the scene by using same image1 sprite, actually you just adding the same object that already on the game stage. [b]The goal is create second instance of your sprite and that's all.[/b] Turn left/right can be done by reversing source hero image by x axis [img]http://public.gamedev.net//public/style_emoticons/default/smile.png[/img] In ActionScript it can be done by replacing hero image each time key pressed. Yeap, playing hero animation is very simple.
  10. Smoking DirectX
  11. [quote name='JETerán' timestamp='1346367460' post='4974951'] Following your suggestion, what I'm going to do now is create a StoreCreation.as file that extends GameObjects instead of Sprite (right??) [/quote] If your GameObjects class extends from Sprite - yes, StoreCreation will automatically be extended hierarchically from Sprite. But do not miss that thing that you should clean up your game object storage when objects does not needed anymore - that's performance important tip. I think you on the right way
  12. Always welcome [img]http://public.gamedev.net//public/style_emoticons/default/smile.png[/img] What type of event listener you've added? You said, that you add 3 event listeners. I think, you should do that separately. Player in first room. Add event listener, that will test collisions for first room objects. Player hits door to second room. Remove event listener for first room collision testing. Remove first room display objects from the scene. Add all objects for second room to the scene. Add event listener for second room collision testing. When I say "Add event listener", I don't mean, that you should have three methods for each room. You may use only one method and store current room index, where player is at the moment. So, I can rewrite algo: Player in first room. [b]Set _currentRoom variable to 1[/b] Add event listener, that will test collisions for first room objects. [b]Right here I'm using _collisionObjectsContainer[_currentRoom] and that's it - I've got list of first room collision objects[/b]. Player hits door to second room. [b]Set _currentRoom variable to 2[/b] Remove event listener for first room collision testing. Remove first room display objects from the scene. Add all objects for second room to the scene. Add event listener for second room collision testing. After such reimplementation you can adopt this algorithm as base for all of your game stages.
  13. I think, you should remember in what room your player right now. After that you can use three containers: each container for 1 room. These containers should contain list of objects for collision testing from each room. And I think that's will be goal: after that you can successfully remove collision objects from first room, when your player inside second or third room.
  14. [quote name='JETerán' timestamp='1346340729' post='4974830'] As always, thanks Deft for your reply [img]http://public.gamedev.net//public/style_emoticons/default/biggrin.png[/img] Ok I saved that tip, I will always delete event listeners after use, thanks !! About this code, what I have is just an event listener that's a ENTER_FRAME, if I wanted to remove it, will be a mess. So, to make it more clearly, I think will be better to have many event listeners, one for each collision with the left and right invisible walls; am I right?? How can I add an event listener that knows f.i. leftLimits is touched by hero?? Thanks SO much once again !! [/quote] I've not recommend to add one event listener per each collision object, especially, if you call them for each call - it is overhead in performance, and be sure - it will be performance issue. The problem is that you want to test object collisions after you removed this object from stage. You cannot test collisions if some object is out of stage. If you had caught collision and do stage clean up, you may assume that collision tests should be stopped before doing this work. And moreover you need to clean up all events and objects, because in other cases you will get performance problems after loading few levels. I hope, I understood what do you want )
  15. Thank you a lot. Now I understand what to do [img]http://public.gamedev.net//public/style_emoticons/default/smile.png[/img]