Jump to content




Get function Code

lua api computer

  • You cannot reply to this topic
4 replies to this topic

#1 Sewbacca

  • Members
  • 450 posts
  • LocationStar Wars

Posted 17 January 2016 - 08:40 PM

Is there a way to get the code of a function, without sub it out the program (I mean string.sub(...))?

#2 Creator

    Mad Dash Victor

  • Members
  • 2,168 posts
  • LocationYou will never find me, muhahahahahaha

Posted 17 January 2016 - 08:58 PM

string.dump(thefunction), but it will error when you dump a java function.

#3 apemanzilla

  • Members
  • 1,421 posts

Posted 17 January 2016 - 09:45 PM

View PostCreator, on 17 January 2016 - 08:58 PM, said:

string.dump(thefunction), but it will error when you dump a java function.

That gets the bytecode for a function. Hardly useful at all, and definitely not what OP was looking for.

#4 Bomb Bloke

    Hobbyist Coder

  • Moderators
  • 7,099 posts
  • LocationTasmania (AU)

Posted 17 January 2016 - 09:55 PM

View PostSewbacca, on 17 January 2016 - 08:40 PM, said:

Is there a way to get the code of a function, without sub it out the program (I mean string.sub(...))?

You can use other string library functions, but long story short, you need access to the original source to do anything with the original source.

#5 Sewbacca

  • Members
  • 450 posts
  • LocationStar Wars

Posted 18 January 2016 - 06:16 PM

Thanks anyway





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users