Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / Does AGK not have a LOG function?

Author
Message
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 26th Aug 2015 18:41 Edited at: 26th Aug 2015 18:46
By that I mean a mathematical logarithm and not the write to log file command that does seem to exist.
It's hard to believe it would be missing but I can't seem to find it.

AGK V2 user - Tier 1 (mostly)
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 26th Aug 2015 20:05
It really does seem to be missing so until such time as it gets implemented (if ever), here is a natural Log function:


AGK V2 user - Tier 1 (mostly)
Markus
Valued Member
20
Years of Service
User Offline
Joined: 10th Apr 2004
Location: Germany
Posted: 26th Aug 2015 20:35
can u tell me what is the usage for log in a game?

AGK (Steam) V2 Beta .. : Windows 10 Pro, 8.1 Pro 64 Bit : AMD (15.7.1) Radeon R7 265 : Mac mini OS X 10.10 (Yosemite)
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 26th Aug 2015 20:38
Certainly:
Determining a power of 2 value dependant upon an unknown width for procedurally generating a 2D terrain.

AGK V2 user - Tier 1 (mostly)
Hodgey
15
Years of Service
User Offline
Joined: 10th Oct 2009
Location: Australia
Posted: 26th Aug 2015 20:58
I wrote an approximation function ages ago which I originally placed inside the Useful community function which seems to have been deleted - not sure why.

http://forum.thegamecreators.com/?m=forum_view&t=211604&b=41

You can specify a base, the value and accuracy (from memory 30 gives an accurate result).

There are no bounds checking so if you pass in mathematically invalid values, it'll still return something.

So that's there if anybody needs it.
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 26th Aug 2015 21:03
It still exists - it got moved to the Newcomers AppGameKit Corner

AGK V2 user - Tier 1 (mostly)
Markus
Valued Member
20
Years of Service
User Offline
Joined: 10th Apr 2004
Location: Germany
Posted: 26th Aug 2015 22:21 Edited at: 26th Aug 2015 22:52
Quote: "Certainly:
Determining a power of 2 value dependant upon an unknown width for procedurally generating a 2D terrain."


???

did you use it to repeat something from how it looks?

for me its just a random terrain from left to the right screen
but the randomness have a seed.

for a terrain i think i would simulate the density in height
and then sag together.

AGK (Steam) V2 Beta .. : Windows 10 Pro, 8.1 Pro 64 Bit : AMD (15.7.1) Radeon R7 265 : Mac mini OS X 10.10 (Yosemite)

Login to post a reply

Server time is: 2024-11-16 20:32:13
Your offset time is: 2024-11-16 20:32:13