question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Hello!

Why when you add code to the file PlayerCell.js

PlayerCell.prototype.onEat = function(prey) {
   this.owner.exp += 1; //((Math.sqrt(prey._sizeSquared)) / 20)
};

when I start to play and eat cells, the supply is not increased. Even if I add myself 1000 weight and eat cells, the mass still does not increase. What to do? The error console does not give.

If you don’t know the solution to this problem, then please do not intervene because I need a solution which is checked. I’ll close the question once I get an answer on this issue. FOR ME CLOSE IS NOT NECESSARY!

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:4
  • Comments:15

github_iconTop GitHub Comments

6reactions
gyeyoqucommented, Sep 2, 2017

@TopoR1 Regarding the question, you will never increase the mass with that small value, since you lose more mass than you gain

5reactions
TopoR1commented, Sep 3, 2017

@FantasyIsBae Here custom only

this.owner.exp +=1;

and the rest is taken from the file cell.js which is a server and related exactly to this problem.

Paste the file into the playerCell.js a normal function

PlayerCell.prototype.onEat = function() { };

and you will see that it is not working properly and needs fixing.

and I’m sure you’re not in check, you only have to defend their point of views and not to help people.

Round

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error Definition & Meaning - Merriam-Webster
a · an act or condition of ignorant or imprudent deviation from a code of behavior ; b · an act involving an...
Read more >
error - Wiktionary
(uncountable) The state, quality, or condition of being wrong. · (countable) A mistake; an accidental wrong action or a false statement not made...
Read more >
Error | Apple Developer Documentation
A type representing an error value that can be thrown.
Read more >
Error Definition & Meaning - Dictionary.com
error · a deviation from accuracy or correctness; a mistake, as in action or speech: His speech contained several factual errors. · belief...
Read more >
66 Synonyms & Antonyms for ERROR - Thesaurus.com
Find 66 ways to say ERROR, along with antonyms, related words, and example sentences at Thesaurus.com, the world's most trusted free thesaurus.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found