Skip to main content
gamedev.net
🔒 Locked

[java] Java RPG background engines

Started by alaskamatt17 0 replies 250+ views
Original Post
alaskamatt17
alaskamatt17
I need a background method that updates the level based on an experience formula. I thought that somebody in here might have done this sort of thing before. I just want the experience to go up like this: Level 0: experience 0 1: 1000 2: 2000 3: 3000 4: 5000 5: 8000 6: 13000 It is a lot like the Fibonacci sequence, except it doesn''t have one twice in the beginning.
Petr Stedry
Petr Stedry
Hi,

this is the Fibonacci sequece.

And the following is true

level(n) = fibonacci(n-1)

And the background function is VERY easy. Just precompute the first N numbers in the sequence and store them in an array.

and don''t forget to have fun
Petr Stedry

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.