Author Topic: $success  (Read 1062 times)

Just wondering how this works for using eval(stuff here);.

It's the exact same thing as entering something into the console.

It's the exact same thing as entering something into the console.
:l

eval("echo(\"hello world\");");

eval runs functions and does more, it's pretty useful

He means for the thing where he can allow a super admin to break his files.

eval(%text @ "%success = 1;");
if(%success) bla bla bla

This was in Slick's eval thing he gave Emo Freak. I tried to add abuse protection, but failed.

Yes, it tries to set success. If it's not set to 1, then the eval didn't go through, so it warns that.

HEY CHRONO! Want to take a run over my code and help me figure out where I went wrong making eval protection? :S

This was in Slick's eval thing he gave Emo Freak. I tried to add abuse protection, but failed.

Yes, it tries to set success. If it's not set to 1, then the eval didn't go through, so it warns that.

HEY CHRONO! Want to take a run over my code and help me figure out where I went wrong making eval protection? :S
hey; gtfo.




edit for info: it appends (adds to the end of your eval) a variable that checks for success. The way code works is it executes each line one at a time, that's why you can do things like %variable = 1; if(%variable==1) and other things. If it encounters an error, it stops executing and will never get to the %success=1; part, so then when it checks later it will notice that something went wrong.
« Last Edit: July 21, 2010, 12:25:24 AM by Triple Nickels »

So, something like this:

-snip-

I'm guessing that Kalphiter's response to that means it should work.
« Last Edit: July 21, 2010, 02:40:36 PM by otto-san »

Way to post it you moron.
But then again, morons don't know what to do with it.

Way to post it you moron.
But then again, morons don't know what to do with it.
way to call me a moron to post a script i had put together