Added 20 hours 17 minutes ago
nn = GetDate(ABSOLUTE_DAY) / 7
---
n = random (179) + 1
AddHeroCreatures(hh[gen] , n , nn * ?)I have this question: I need a random creature to appear for the hero, but its quantity should depend on the current week * a special coefficient, unique for each monster in the game; I've already defined it. The problem is that I can't fit all of this into one line. Maybe it's possible to create an array of 179 values, for example, c[0] = 1, c[1] = 10, c[179] = 2, etc., and then, instead of ?, substitute c[n] into the above function? But, unfortunately, it doesn't work. What should I do? I hope for help.