Search Results

Search found 10 results on 1 pages for 'melee'.

Page 1/1 | 1 

  • Making a physicalized melee weapon

    - by xuincherguixe
    The short version, is that I was asked to look into the feasibility of making a melee weapon, that one could swing at another object in the game, and have it interact physically. I completed the tutorial here http://www.mavrikgames.com/tutorials/melee-weapons, and proved that indeed it is. The thing is, that only for a brief period in the swing is the sword capable of knocking things around. I've looked through the editor and code for awhile now, and I'm still not sure how to do this. I was able to lengthen the amount of time it takes the animations run for, but not the length of time with which the sword can bash the barrel around.

    Read the article

  • Best way to handle realtime melee AI in authoritative network environment

    - by PrimeDerektive
    So i've been working on a multiplayer game for a bit; it's a co-op action RPG with real-time combat. If you've seen or played TERA, I'd say it's comparable to that, but not an MMO, heh. I'm currently handling the AI units authoritatively, the server calculates their pathing, movement, and pursue/attack logic, and syncs the movement to the clients 15x per second, and the state changes when they happen. When I emulate 200ms ping, though, the client can perceive being out of range to an AI's attack, but still take the hit, because on the server he hadn't moved that far yet. This also plays hell with my real-time blocking. I don't really want to allow the clients to be allowed to say "that was out of range" or "I blocked that", but I'm not really sure how else to handle it.

    Read the article

  • Common Javascript mistakes that severely affect performance?

    - by melee
    At a recent UI/UX MeetUp that I attended, I gave some feedback on a website that used Javascript (jQuery) for its interaction and UI - it was fairly simple animations and manipulation, but the performance on a decent computer was horrific. It actually reminded me of a lot of sites/programs that I've seen with the same issue, where certain actions just absolutely destroy performance. It is mostly in (or at least more noticeable in) situations where Javascript is almost serving as a Flash replacement. This is in stark contrast to some of the webapps that I have used that have far more Javascript and functionality but run very smoothly (COGNOS by IBM is one I can think of off the top of my head). I'd love to know some of the common issues that aren't considered when developing JS that will kill the performance of the site.

    Read the article

  • How does Starcraft 2 load it's metadata?

    - by chobok
    Lets say you are playing Starcraft 2 melee map. The game loads the map. Melee maps have the following dependencies: Liberty (Mod) Liberty Multi (Mod) I think the game engine will load the data from Liberty (Mod) first, then from Liberty Multi (Mod). For data that exists in both dependencies, the engine will use the one from Liberty Multi (Mod). Is this correct? Liberty Multi (Mod) is updated with each patch of Starcraft 2. Does the game engine load just the latest version of Liberty Multi (Mod)? or Does the game engine load all the versions and overwrite duplicate data with the latest version?

    Read the article

  • Simple syntax error still eluding me.

    - by melee
    Here is the header for a class I started: #ifndef CANVAS_ #define CANVAS_ #include <iostream> #include <iomanip> #include <string> #include <stack> class Canvas { public: Canvas(); void Paint(int R, int C, char Color); const int Nrow; const int Ncol; string Title; int image[][100]; stack<int> path; struct PixelCoordinates { unsigned int r; unsigned int c; } position; Canvas operator<< (const Canvas& One ); Canvas operator>>( Canvas& One ); }; /*----------------------------------------------------------------------------- Name: operator<< Purpose: Put a Canvas into an output stream -----------------------------------------------------------------------------*/ ostream& operator<<( ostream& Out, const Canvas& One ) { Out << One.Title << endl; Out << "Rows: " << One.Nrow << " Columns: " << One.Ncol << endl; int i,j; for( i=0; i<One.Nrow; i++) { cout<<"\n\n\n"; cout<< " COLUMN\n"; cout<< " 1 2 3"; for(i=0;i<One.Nrow;i++) { cout<<"\nROW "<<i+1; for(j=0;j<One.Ncol;j++) cout<< One.image[i][j]; } } return Out; } /*----------------------------------------------------------------------------- Name: operator>> Purpose: Get a Canvas from an input stream -----------------------------------------------------------------------------*/ istream& operator>>( istream& In, Canvas& One ) { // string Line; // int Place = 0; // { // In >> Line; // if (In.good()) // { // One.image[Place][0] = Line; // Place++; // } // return In; #endif Here is my implementation file for class Canvas: using namespace std; #include <iostream> #include <iomanip> #include <string> #include <stack> #include "proj05.canvas.h" //----------------Constructor----------------// Canvas::Canvas() { Title = ""; Nrow = 0; Ncol = 0; image[][100] = {}; position.r = 0; position.c = 0; } //-------------------Paint------------------// void Canvas::Paint(int R, int C, char Color) { cout << "Paint to be implemented" << endl; } And the errors I'm getting are these: proj05.canvas.cpp: In function 'std::istream& operator>>(std::istream&, Canvas&)': proj05.canvas.cpp:11: error: expected `;' before '{' token proj05.canvas.cpp:24: error: expected `}' at end of input From my limited experience, they look like simple syntax errors but for the life of me, I cannot see what I am missing. I know putting a ; at the end of Canvas::Canvas() is wrong but that seems to be what it expects. Could someone please clarify for me? (Also, I know much of the code for the << and operator definitions look terrible, but unless that is the specific reason for the error please do not address it. This is a draft :) )

    Read the article

  • error: expected `;' before '{' token - What is the cause?

    - by melee
    Here is my implementation file: using namespace std; #include <iostream> #include <iomanip> #include <string> #include <stack> //line 5 #include "proj05.canvas.h" //----------------Constructor----------------// Canvas::Canvas() //line 10 { Title = ""; Nrow = 0; Ncol = 0; image[][100]; // line 15 position.r = 0; position.c = 0; } //-------------------Paint------------------// line 20 void Canvas::Paint(int R, int C, char Color) { cout << "Paint to be implemented" << endl; } The errors I'm getting are these: proj05.canvas.cpp: In function 'std::istream& operator>>(std::istream&, Canvas&)': proj05.canvas.cpp:11: error: expected `;' before '{' token proj05.canvas.cpp:22: error: a function-definition is not allowed here before '{' token proj05.canvas.cpp:24: error: expected `}' at end of input proj05.canvas.cpp:24: error: expected `}' at end of input These seem like simple syntax errors, but I am not sure what's wrong. Could someone decode these for me? I'd really appreciate it, thanks for your time! EDIT Here is the definition of Canvas in my .h file: #ifndef CANVAS_H #define CANVAS_H #include <iostream> #include <iomanip> #include <string> #include <stack> class Canvas { public: Canvas(); void Paint(int R, int C, char Color); const int Nrow; const int Ncol; string Title; int image[][100]; stack<int> path; struct PixelCoordinates { unsigned int r; unsigned int c; } position; }; #endif

    Read the article

  • Can't see anything wrong with simple code

    - by melee
    Here is my implementation file: using namespace std; #include <iostream> #include <iomanip> #include <string> #include <stack> //line 5 #include "proj05.canvas.h" //----------------Constructor----------------// Canvas::Canvas() //line 10 { Title = ""; Nrow = 0; Ncol = 0; image[][]; // line 15 PixelCoordinates.r = 0; PixelCoordinates.c = 0; } //-------------------Paint------------------// line 20 void Canvas::Paint(int R, int C, char Color) { cout << "Paint to be implemented" << endl; } The errors I'm getting are these: proj05.canvas.cpp: In function 'std::istream& operator>>(std::istream&, Canvas&)': proj05.canvas.cpp:11: error: expected `;' before '{' token proj05.canvas.cpp:22: error: a function-definition is not allowed here before '{' token proj05.canvas.cpp:24: error: expected `}' at end of input proj05.canvas.cpp:24: error: expected `}' at end of input These seem like simple syntax errors, but I am not sure what's wrong. Could someone decode these for me? I'd really appreciate it, thanks for your time!

    Read the article

  • Abstract skill/talent system implementation

    - by kiliki
    I've been making small 2D games for about 3 years now (XNA and more recently LWJGL/Slick2D). My latest idea would involve some form of "talent tree" system in a real time game. I've been wracking my brain but can't think of a structure to hold a talent. Something like "Your melee attack is an instant kill if behind the target" I'd like to come up with an abstract object rather than putting random conditionals into other methods. I've solved some relatively complex problems before but I don't even know where to begin with this one. Any help would be appreciated - Java, pseudocode or general concepts are all great.

    Read the article

  • techniques for an AI for a highly cramped turn-based tactics game

    - by Adam M.
    I'm trying to write an AI for a tactics game in the vein of Final Fantasy Tactics or Vandal Hearts. I can't change the game rules in any way, only upgrade the AI. I have experience programming AI for classic board games (basically minimax and its variants), but I think the branching factor is too great for the approach to be reasonable here. I'll describe the game and some current AI flaws that I'd like to fix. I'd like to hear ideas for applicable techniques. I'm a decent enough programmer, so I only need the ideas, not an implementation (though that's always appreciated). I'd rather not expend effort chasing (too many) dead ends, so although speculation and brainstorming are good and probably helpful, I'd prefer to hear from somebody with actual experience solving this kind of problem. For those who know it, the game is the land battle mini-game in Sid Meier's Pirates! (2004) and you can skim/skip the next two paragraphs. For those who don't, here's briefly how it works. The battle is turn-based and takes place on a 16x16 grid. There are three terrain types: clear (no hindrance), forest (hinders movement, ranged attacks, and sight), and rock (impassible, but does not hinder attacks or sight). The map is randomly generated with roughly equal amounts of each type of terrain. Because there are many rock and forest tiles, movement is typically very cramped. This is tactically important. The terrain is not flat; higher terrain gives minor bonuses. The terrain is known to both sides. The player is always the attacker and the AI is always the defender, so it's perfectly valid for the AI to set up a defensive position and just wait. The player wins by killing all defenders or by getting a unit to the city gates (a tile on the other side of the map). There are very few units on each side, usually 4-8. Because of this, it's crucial not to take damage without gaining some advantage from it. Units can take multiple actions per turn. All units on one side move before any units on the other side. Order of execution is important, and interleaving of actions between units is often useful. Units have melee and ranged attacks. Melee attacks vary widely in strength; ranged attacks have the same strength but vary in range. The main challenges I face are these: Lots of useful move combinations start with a "useless" move that gains no immediate advantage, or even loses advantage, in order to set up a powerful flank attack in the future. And, since the player units are stronger and have longer range, the AI pretty much always has to take some losses before they can start to gain kills. The AI must be able to look ahead to distinguish between sacrificial actions that provide a future benefit and those that don't. Because the terrain is so cramped, most of the tactics come down to achieving good positioning with multiple units that work together to defend an area. For instance, two defenders can often dominate a narrow pass by positioning themselves so an enemy unit attempting to pass must expose itself to a flank attack. But one defender in the same pass would be useless, and three units can defend a slightly larger pass. Etc. The AI should be able to figure out where the player must go to reach the city gates and how to best position its few units to cover the approaches, shifting, splitting, or combining them appropriately as the player moves. Because flank attacks are extremely deadly (and engineering flank attacks is key to the player strategy), the AI should be competent at moving its units so that they cover each other's flanks unless the sacrifice of a unit would give a substantial benefit. They should also be able to force flank attacks on players, for instance by threatening a unit from two different directions such that responding to one threat exposes the flank to the other. The AI should attack if possible, but sometimes there are no good ways to approach the player's position. In that case, the AI should be able to recognize this and set up a defensive position of its own. But the AI shouldn't be vulnerable to a trivial exploit where the player repeatedly opens and closes a hole in his defense and shoots at the AI as it approaches and retreats. That is, the AI should ideally be able to recognize that the player is capable of establishing a solid defense of an area, even if the defense is not currently in place. (I suppose if a good unit allocation algorithm existed, as needed for the second bullet point, the AI could run it on the player units to see where they could defend.) Because it's important to choose a good order of action and interleave actions between units, it's not as simple as just finding the best move for each unit in turn. All of these can be accomplished with a minimax search in theory, but the search space is too large, so specialized techniques are needed. I thought about techniques such as influence mapping, but I don't see how to use the technique to great effect. I thought about assigning goals to the units. This can help them work together in some limited way, and the problem of "how do I accomplish this goal?" is easier to solve than "how do I win this battle?", but assigning good goals is a hard problem in itself, because it requires knowing whether the goal is achievable and whether it's a good use of resources. So, does anyone have specific ideas for techniques that can help cleverize this AI? Update: I found a related question on Stackoverflow: http://stackoverflow.com/questions/3133273/ai-for-a-final-fantasy-tactics-like-game The selected answer gives a decent approach to choosing between alternative actions, but it doesn't seem to have much ability to look into the future and discern beneficial sacrifices from wasteful ones. It also focuses on a single unit at a time and it's not clear how it could be extended to support cooperation between units in defending or attacking.

    Read the article

  • Blending animations for more character movements

    - by Noob Saibot
    I am making a hack n slash 3rd person game. And I want the character movements to be more dynamic not like fighting games where you have a moves list. I want to animate tons of different animations and have them "Tween" between each other? Because I want the controls to not be keyboard mouse. I want it to be all keyboard. that way you have up to 10 inputs (All your fingers) to blend and morph animations to create more fluid movements. In the end this will almost be similar to characters typing a phrase or string of keys rather than move forward mouse look click to melee. My question is. Has anyone done this before and would someone go about trying to tween lets say one for key on the keyboard excluding Tab, Caps, R+Shift, L+Shift, Enter, R+Ctrl, L+Ctrl, L+Alt, R+Alt, Windows Key, and Menu. So thats all the numbers, letters and punctuation keys. Thats 46 keys gives me a combination of 46P1 = 5502622159812088949850305428800254892961651752960000000000L (used Python) and with a minimum entry value of 2 keypresses shortening to half. This is not humanly possible to create so many inique animations in one lifetime. But I'm guessing there is a reason this hasn't been done already. Or if I just used 10 basic keys. Maybe ASDF SPACE (RIGHT HAND) 456+0 (LEFT HAND KEYPAD) it would give me 3,628,800 posible unique animations.

    Read the article

1