Navigation

    forum

    • Login
    • Search
    • Categories
    • Recent
    • Popular
    • Users
    • Groups
    1. Home
    2. rndr
    3. Posts
    • Flag Profile
    • block_user
    • Profile
    • Following
    • Followers
    • Topics
    • Posts
    • Groups
    • Blog

    Posts made by rndr

    • RE: Optimal CPU usage - findInRange or lookForAtArea

      And i just realized that simplest way to look at the code is to look at the prototype, and not trying to find instance

      RoomPosition.prototype.findInRange
      posted in Help
      rndr
    • RE: How much time is needed to spawn a creep ?

      there is also game const in case it changes in future

      CREEP_SPAWN_TIME: 3
      posted in General Discussion
      rndr
    • RE: Optimal CPU usage - findInRange or lookForAtArea

      I think first thing to do would be check if it's a problem at all, you can do that with a profiler: https://github.com/gdborton/screeps-profiler/ , premature optimization and optimization without profiling are not good most of the time.

      Also the profiler can profile specified function if you pass functionFilter to it, so you can profile both variants with simple for i in range something test loop (and you will probably have to enable profiler only at the end of the main loop and do test for loop after that, so game functions monkey-patched only for testing for loop).

      And also for most public game functions you can look at their code by inserting function name in console and pressing enter, it is not always helpful but in case of RoomPosition.prototype.findInRange you can see in code that it does call room.find

       

      function (type, range, opts) {
      var room = register.rooms[this.roomName];

      if (!room) {
      throw new Error(`Could not access room ${ this.roomName }`);
      }

      opts = _.clone(opts || {});

      var objects = [],
      result = [];

      if (_.isNumber(type)) {
      objects = room.find(type, opts);
      }
      if (_.isArray(type)) {
      objects = opts.filter ? _.filter(type, opts.filter) : type;
      }

      objects.forEach(i => {
      if (this.inRangeTo(i, range)) {
      result.push(i);
      }
      });

      return result;
      }

       
      posted in Help
      rndr
    • RE: Feature request: not allowing to spawn right next to players

      The punishment for respawn is too harsh. Respawn throws whatever you have in garbage can, meaning you wasted you time and money on absolutely nothing. Right now respawn is like you play some MMORPG (lineage 2, wow, whatever is popular these days) and you get to whatever level you get, you die, and you loose all your items and skills and the only thing left is useless level number. I don't feel like doing exact same things over again, even when it means sitting 2 weeks and watching creeps do their job.

      posted in Feature Requests
      rndr
    • Feature request: not allowing to spawn right next to players

      I'm surrounded by guys with 2 towers, i can't kill them and have no exit to area center or borders or any room to seize at glc3. Whatever i achieved is useless, i don't feel like playing anymore, and i'm simply waiting for my subscription to expire or my neighbours to kill me or both. I admit, i've fucked up, i shoud have killed everyfuckin newbie i could before it's too late no matter how disappointed they gonna be in game. Or chosen different room at the beginning, steep learning curve makes you not able to make informed decision about such things until it's too late, imho.

      Please don't let retards like me to fuckup themselfs in future and dissallow spawning next to players (diagonals and no-exits don't count) at least at newbie areas.

      PS: sorry for being emo about it.

      posted in Feature Requests
      rndr
    • RE: avg tick duration climbing up
      • If there is a suggestion I could offer it would be this, there should be some additional way for me to give money to the developers.

      TOS prohibit you from registering new account to play game, it says nothing about registering new account and never spawning. If you can (have money to) support developers and the thing you want is supporting developers and not lobbying your interests or pay2win, then everybody will be glad if you create as many new account as you want, pay subscription and never spawn on them.

      • it had been at 2.5 seconds per tick looong before steam release, actually.

      I was not subscribed at the time, and at the time there were no status page for screeps, but when i found out about the game (few days before steam release) on multiple occasions i found messages from players saying that tick duration is 1-2 seconds. If that (2.5s) is the case, i'm sorry for misinformation.

      • Also, Screeps used to have that "pay for what you use" system before it was scraped for the current payment model, and it made the game way more approachable and interesting at the same time.

      I know that, i'm not suggesting that, i'm suggesting pay for fixed (and equal for everyone) amount of ticks model. You pay for N ticks and if tick duration is 3 real world seconds your script is running with whatever CPU restrictions (equal or based on GLC) you have for 3*N real world seconds (not CPU seconds), if tick duration is 10 real world seconds your script is running with whatever CPU restrictions (equal or based on GLC) you have for 10*N real world seconds (not CPU seconds).

       

      If tick duration growth is inevitable and player base is willing to pay for current model, the other suggestion that i have is balancing out energy (and probably minerals too) according to tick duration, enlarge the amount of energy sources have, amount of energy per WORK part harvested e.t.c. so amount of proggres per real world time stays same with tick duration growth.

      posted in General Discussion
      rndr
    • avg tick duration climbing up

      The change that kinda bothers me is the fact that ever since steam release avg tick duration was climbing up and changed from ~1.5 (UPD: players in comments say it was 2.5 during steam release, but no mater time frame it is obviously growing with the amount of players in game) to >3 (3.13 last week, 3.51 last 24 hours, 3.78 last 10 minutes atm of post creation) which may seem like not much but if you consider the 24/7 fact then you kinda realize that it means you progress >2 times slower already, you wait 2 times more for things to happen, you harvest 2 times less energy per real world day, you upgrade you controller to next RCL 2 times longer, and basically you buy less progress for the same subscription price. The game was slow paced, and now it's 2 times slower then slow paced. The CPU system imho already seams kinda not 100% fair since the amount of goods you receive for the price differs based on your GCL (which mostly, differs with real world expirience, buying VPS for instance), but at least it encourages new players to write better code. But, again, imho max room count is big enough reward for GLC and trading (equally limited for all players) CPU time in the begging for efficiency (billion little checks for range to everything? billion little creeeps that chain from source to controller in pre-Link room? and other crazy CPU eating creative stuff) and profiling\optimizing as you progress seam like fun too. If ~constant tick duration is not possible (which it seam like), wouldn't it be fair for players be billed based on amount of ticks code gets executed? If not, would you, player, change your mind if in a week it will grow to 5s per tick? 20s per tick in a month?

       

      UPD:

      If tick duration growth is inevitable and player base is willing to pay for current model, the other suggestion that i have is balancing out energy (and probably minerals too) according to tick duration, enlarge the amount of energy sources have, amount of energy per WORK part harvested e.t.c. so amount of proggres per real world time stays same with tick duration growth.

      posted in General Discussion
      rndr
    • RE: visual sign on creeps for scripting use (e.g. role)

      I am, i use it too since there is nothing better, but it has disadvantages:

      1. Creep.say has big say bubble that hides name, other creeps and others creep bubbles
      2. creep.say as of now is const cpu (0.2) on each call, but it's NONE cost on PTR
      3. And It makes hard to point at something like where creep is going, you can shout coords but coords are inconvenient to find in room and id's are even more inconvenient and not fully fit in bubble. (Colors\Prefixes don't help with that either, but drawLine does)
      posted in Feature Requests
      rndr
    • direct links to room replays in notifications

      For notifications like 'Your creep Creep in room Room is under attack!' and other ones that have exact room and time location, it would be helpful to have link to exact tick in room replay because if something unexpected happens you go to replay and see what was that anyway. At some point replay will expire, but from my experience it does not matter since most of the times i read notification at least once a day.

      posted in Feature Requests
      rndr
    • RE: visual sign on creeps for scripting use (e.g. role)

      Some other suggestions:

      1. Ability to draw line from RoomObject\RoomPosition to RoomObject\RoomPosition (with cpu const cost) would be cool to. Will help to display\debug where exactly creep going\what is he targeting e.t.c. To differentiate between shooting\working lines and debug lines debug lines could be dotted\dashed. With optional coloring.
      2. Possible ability to have something like creep name prefix for createCreep method, when prefix is passed to createCreep and name is not, name is chosen randomly and then prefixed with prefix, this way you can at glance see some info about creep (role, if player choices to use roles), but freed from writing unique\sequence name generator, where there is one already ingame.
      posted in Feature Requests
      rndr
    • RE: User interface - LARGE

      .
      posted in Help
      rndr
    • RE: Extreme increase in CPU usage with the same script since the Withdraw update
      • Hm, I see, but what real-world scenarios would involve spawning a creep in the middle of iteration through Game.creeps? Seems like bad code organization anyway.

      Spawning copy of soon-to-be-dead or some other creeps?

      Not doing it, but someone might.

      posted in Technical Issues and Bugs
      rndr
    • RE: Screeps Crashing ?

      infinite loop? did you mean number-- in both for loops?

      for (;number > 0; number++)
      posted in Help
      rndr