Spoiler (click to show/hide):
What exactly am I doing wrong? Am I just bad at programming?
Anyway, yeah, if I can't figure out what's wrong, I may just focus on the story, enemies, factions, and other such things for now.
var Entity = function (health, lust, strength, resilience, willpower, intelligence, libido, speed) {
[...]
var player = Entity(500, 0, 10, 10, 10, 10, 10, 10);
var selectedmonster = lesser_witch(250, 0, 5, 5, 10, 15, 15, 10);
var selectedmonster = goblin(100, 0, 15, 15, 5, 5, 15, 5);
var selectedmonster = lilith(500, 0, 25, 25, 25, 25, 25, 25);
if (randomnumber >= 0 && randomnumber < 3){
selectedmonster = lesser_witch;
names = "Lesser Witch";
}
else if (randomnumber > 3 && randomnumber < 6){
selectedmonster = goblin;
names = "Goblin";
}
else if (randomnumber > 6){
selectedmonster = lilith;
names = "Lilith";
}
BlueLight Wrote:okay so just looking at the other post; you need better coding hygiene. For instants never use a plural version of a word for a variable,method, or class. I break this rule when dealing with arrays.
Variables tend to be nouns while methods(functions) are verbs. Classes are also nouns.
Ctrl+f is your friend. This will let you search for words or sets of characters. A program designed for programming can not only do that but also replace the words or sets of characters with another set. Notepad++ is one i suggest you pick up. This would allow you to find all instances of "Players" and turn it into "player".
Users browsing this forum: No registered users