Jump to content
  • Advertisement

Weberet

Member
  • Content Count

    9
  • Joined

  • Last visited

Community Reputation

125 Neutral

About Weberet

  • Rank
    Newbie
  1. Thanks for the help and suggestions everyone, its been been very helpful!
  2. I've written a script to split the screen which I'll include below, the problem with the script is it does not split the screen according to how many players are present. The screen is meant to always split down the middle but instead splits the screen with the center point somewhere around the upper left hand corner of the screen, I have tried setting the variables according to the display dimensions and the window dimensions (application runs full screen.) Does anybody have any ideas of what might be wrong with the below script? Sorry for the rushed post, headed out at the moment, will probably edit and upload screenshots later. Any help would be much appreciated, Thanks! Script:   //dwidth = floor(display_get_width()); //Display Height //dheight = floor(display_get_height()); //Display Width dwidth = floor(window_get_width()); //Display Height dheight = floor(window_get_height()); //Display Width view_object[0] = obj_player; view_object[1] = obj_player2; view_object[2] = obj_player; view_object[3] = obj_player; xp1 = 0; yp1 = 0; wp1 = dwidth; hp1 = dheight; switch(numplayers){ //Currently set it this objects on create event. case 1: //1 Player xp1 = 0; yp1 = 0; wp1 = dwidth; hp1 = dheight; view_xport[0] = xp1; view_yport[0] = yp1; view_wview[0] = wp1; view_hview[0] = hp1; view_visible[0] = true; view_visible[1] = false; view_visible[2] = false; view_visible[3] = false; break; case 2: //2 Players xp1 = 0; yp1 = 0; wp1 = dwidth/2; hp1 = dheight; xp2 = dwidth/2; yp2 = 0; wp2 = dwidth/2; hp2 = dheight; view_xport[0] = xp1; view_yport[0] = yp1; view_wview[0] = wp1; view_hview[0] = hp1; view_xport[1] = xp2; view_yport[1] = yp2; view_wview[1] = wp2; view_hview[1] = hp2; view_visible[0] = true; view_visible[1] = true; view_visible[2] = false; view_visible[3] = false; break; case 3: //3 Players xp1 = 0; yp1 = 0; wp1 = dwidth; hp1 = dheight/2; xp2 = 0; yp2 = dheight/2; wp2 = dwidth; hp2 = dheight/2; xp3 = dwidth/2; yp3 = dheight/2; wp3 = dwidth; hp3 = dheight/2; view_xport[0] = xp1; view_yport[0] = yp1; view_wview[0] = wp1; view_hview[0] = hp1; view_xport[1] = xp2; view_yport[1] = yp2; view_wview[1] = wp2; view_hview[1] = hp2; view_xport[2] = xp3; view_yport[2] = yp3; view_wview[2] = wp3; view_hview[2] = hp3; view_visible[0] = true; view_visible[1] = true; view_visible[2] = true; view_visible[3] = false; break; case 4: //4 Players xp1 = 0; yp1 = 0; wp1 = dwidth/2; hp1 = dheight/2; xp2 = dwidth/2; yp2 = 0; wp2 = dwidth/2; hp2 = dheight/2; xp3 = 0; yp3 = dheight/2; wp3 = dwidth; hp3 = dheight/2; xp4 = dwidth/2; yp4 = dheight/2; wp4 = dwidth; hp4 = dheight/2; view_xport[0] = xp1; view_yport[0] = yp1; view_wview[0] = wp1; view_hview[0] = hp1; view_xport[1] = xp2; view_yport[1] = yp2; view_wview[1] = wp2; view_hview[1] = hp2; view_xport[2] = xp3; view_yport[2] = yp3; view_wview[2] = wp3; view_hview[2] = hp3; view_xport[3] = xp4; view_yport[3] = yp4; view_wview[3] = wp4; view_hview[3] = hp4; view_visible[0] = true; view_visible[1] = true; view_visible[2] = true; view_visible[3] = true; break; default: // Single player visible with all other variables set to various default values. xp1 = 0; yp1 = 0; wp1 = dwidth; hp1 = dheight; xp2 = 0; yp2 = 0; wp2 = dwidth; hp2 = dheight; xp3 = 0; yp3 = 0; wp3 = dwidth; hp3 = dheight; xp4 = 0; yp4 = 0; wp4 = dwidth; hp4 = dheight; view_xport[0] = xp1; view_yport[0] = yp1; view_wview[0] = wp1; view_hview[0] = hp1; view_xport[1] = xp2; view_yport[1] = yp2; view_wview[1] = wp2; view_hview[1] = hp2; view_xport[2] = xp3; view_yport[2] = yp3; view_wview[2] = wp3; view_hview[2] = hp3; view_xport[3] = xp4; view_yport[3] = yp4; view_wview[3] = wp4; view_hview[3] = hp4; view_visible[0] = true; view_visible[1] = false; view_visible[2] = false; view_visible[3] = false; break; }
  3. Actually think I found the results I want by implementing what I mentioned above! Now I just need to adapt my script for game pads which I'll have to do when I have one with me. Current Script:   /*Movement Code*/      if (captained){ /*Turn Radius Limit Script, Based off ship speed:*/ turnradratio = speed/shiptspeed; if keyboard_check(vk_left) {      direction += tradius*turnradratio; } if keyboard_check(vk_right) {      direction -= tradius*turnradratio; } if keyboard_check(vk_up) {     if (speed < shiptspeed){     speed += acceleration;     }     else{speed = shiptspeed}; } else if keyboard_check(vk_down) {     speed -= acceleration; } else{ //No keys being pressed; /*Detect speed and decelerate towards 0*/ if (speed > 0){speed -= drag;} else if (speed < 0) {speed  += drag;} } image_angle = direction;     } Any suggestions on improvements?
  4. Thanks for the responses everyone! I did a little bit more research based on kburkhart84 description of "Asteroids" like movement. (After recognizing that would probably be an easier term to look for.) And came back to post my results only to find that ferrous had already written a similar script! So far the below script is yielding good results and it will work for my testing purposes, however I'd like to refine it more. The biggest change I think I want to implement is to make its so that the faster the ship moves the more it is able to turn and making it so that the ship can not turn when it is stationary. Would the best way to do this is create a variable that checks for how fast the boat is going currently to its top speed, create a ratio, and then apply that ratio to the ships turn radius?   /*Ship Variables:*/ tradius = .5 //How quickly ship can turn shipmpeed = 0; // Minimum Speed shiptspeed = 5; // Maximum Speed acceleration = .1; //Acceleration drag = .1; //Friction, slows object down /*Ship Movement*/ if keyboard_check(vk_left) {      direction += tradius; } if keyboard_check(vk_right) {      direction -= tradius; } if keyboard_check(vk_up) {     if (speed < shiptspeed){     speed += acceleration;     }     else{speed = shiptspeed}; } else if keyboard_check(vk_down) {     speed -= acceleration; } else{ //No keys being pressed; /*Detect speed and decelerate towards 0*/ if (speed > 0){speed -= drag;} else if (speed < 0) {speed  += drag;} } image_angle = direction;  
  5. I am currently working on a game in Yoyo game's: Game Maker software. The game involves top down ships ( large watercraft ) moving. I'm running into one roadblock so far and that is that I am unsure of how to script movement for a top down vehicle such as this. I'm looking to create movement similar to that in the game "Sunless Sea." (I read somewhere that this would be considered "nonholonomic" movement.) I am trying to avoid using the game maker physics functions and am planning on eventually having this be controlled by a game-pad (probably an ps3 or ps4 controller emulating a xbox controller.) Has anybody written any scripts like this for ship movement? For those unfamiliar with GML I have a super basic script I found for basic top down movement that I am currently using just to test ship interactions with other objects, mainly to show a little bit of the languages syntax and basic functions:   /*Temporary Movement Code*/ if (keyboard_check(vk_up) && keyboard_check(vk_right))     {x+=2; y-=2;}     else if (keyboard_check(vk_up) && keyboard_check(vk_left))     {x-=2; y-=2;}     else if (keyboard_check(vk_down) && keyboard_check(vk_right))     {x+=2; y+=2;}     else if (keyboard_check(vk_down) && keyboard_check(vk_left))     {x-=2; y+=2;}     else if keyboard_check(vk_up)     {x+=0; y-=4;}     else if keyboard_check(vk_left)     {x-=4; y-=0;}     else if keyboard_check(vk_down)     {x+=0; y+=4;}     else if keyboard_check(vk_right)     {x+=4; y-=0;} // End Any help, or helpful resources would be much appreciated! Thanks! :D  
  6. Okay, updated the mind map to reflect the suggestions I would like to incorporate. Figured I do want the graphics and gameplay to be a little more on the "whimsical" side then realistic. I want to do some satisfying sounds and animations with particle effects opposed to ant corpses being torn apart. Decided I want to go 2D top down for the graphics with a UI themed around how other RTS games do it. Want it to be simulation RTS with a HUD like SC2 or Empire Earth, etc. Think I am going to build a system where you can zoom in and out on different portions of the map to check on the action going on. Want the units to be semi-autonomous, never idle like a true ant. Can be given orders but do random helpful jobs without. Listed a couple nest types, unit types, upgrades, etc in the mind map. My next plan is to implement how I want to have the game started and the ultimate goal I have decided is to either be eliminate all other colonies, or control a certain amount of land. Not sure which I like better but feel that eliminating all other colonies would be coolest. Been researching some different real species of ants for a look into special units and abilities, possibly races. Think I will have a set of base stats for each race if I decide to do races. One of my big conundrums is figuring how I want resources to appear and be distributed for interesting game play. As well as possibly thinking of a couple more resource types and what they would be used for. So far I only have food, water, and nest which I find limiting. Will keep posted on how the concept is shaping up, but for now, a picture of the updated mind map:
  7. I do like the idea for nest upgrades, and unlocking new units as you go. Playing with the idea of each ant, or maybe type having different stats. Leveling up the longer the ant lives maybe. Nest upgrades, I'm thinking extra nest HP, Capacity increase, maybe some sort of economic advantage. All very nice, adding to the mind map.
  8. @ WildField Sorry about the vagueness, totally agree with you that its not very far along or refined! If it helps I do want to do it top down, really fun graphics (Cartoon or pixel, non real) On a Procedurally generated world map so that every play is different. I also like @klefebz idea of keeping it economy/structure centered, making the goal to take over the map, or maybe eliminate all other ants by out-building, out-managing your colony.   @klefebz The other unit types are very helpful, I was straining my mind trying to think of what other ant related units could possibly exist! I will be adding your types to my mind map immediately. Your right about the goal as well, I will be thinking that through some more. I kind of like the idea of eliminating all other competing ant colonies though. Good control scheme suggestions as well, I like the task flag one, being ants I kind of want them to be semi-autonomous but I still want there to be an element of control. I want to make you feel like you are controlling a super organism instead of scattered ants.   @Orymus3 I'll be looking at the games you guys have referenced to help decide the direction. I actually have a pretty fun example for myself of underground room management, you should check out a currently alpha game being released on steam called Gnomoria, I think you would find the underground room management interesting as most everything can be built underground, I would not mind taking a few leaves out of Gnomoria for this game. Yes still very vague and undeveloped, wrote to @WildField above about a little bit of that, don't know if it helps at all. I do like the idea of a semi-autonomous command system. I will be checking out Microids as well   @Meatsack, I will be checking that out as well! Thanks for the awesome input thus far everyone!
  9. Short Intro   (Scroll Down to get to the point if you don't like reading cirumstances.) Hello, New to the gamedev.net community but have made a few limited games a couple years ago using very basic software and loved every minute of it.   In the past, my projects have always been not really thought out, kind of just change as I go, experiment, find something that works, and I want to change that with this one. I want to start my project knowing what the game should become, and what I want it to become. Refined mechanics, graphics, gameplay, etc. I want to create something with some real thought.   I've been thinking about for my next game/application, and I thought of the idea of an Ant Colony Simulation Game.   So I set to work with the concept of Ant Colony Simulation Game and got some of the basics thrown out there, then wondered If I was the only one who was going to find this project interesting. Which led to me coming here to attempt to get some external input to really bring some ideas to the table that appeal to a broader audience then myself. I use a free mindmapping software called free mind for my concepts as I feel it allows me to throw my ideas out fast and organize them a bit. Here is a screenshot of my mindmap for the simulation concept:   The Concept in Mind Map format:       The Inquiries:   1. The idea? Good, bad, stupid, brilliant? Elaborate (I like to know why.)   2. Any thing that you would like to see done with the concept? Multi-player, skirmishes, customizations, combat systems, controls, anything? etc.   3. Anything you can think of to add to my mind map? (List parent node, then idea.)   4. Control systems you would like to see? Fully Autonomous, Fully Micro-managed, mix?   5. Any other input you would like to give!     Any helpful input is much appreciated! Thanks!   -Weberet
  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!