Search results

  1. N

    Alternate Trade Response Script

    Heh, it shouldn't be too hard, well a basic "static X item/s and meat for Y item/s and meat", type shouldn't, a "X meat per Y item" shouldn't be too hard either, I'm just worried about the "X of S or O or M or E item/s and meat for Y item/s and meat". I'll see what I can whip up, if I have...
  2. N

    failed or succeeded?

    Does your script end with a if check. I believe mafia will just print out the result of the last boolean check IF there is no "else". So: print( "Script working."); if( 1==2) { print( "... Okay... *backs away slowly from computer*"); } Would return failed (I hope). I guess in a sense it did...
  3. N

    auto smile script.

    today_to_string() is your friend! YYYYMMDD format (Yeah no "/" or anything just all numbers). Assuming your in a time zone that in terms of "relative to KoL rollover" isnt too different. Since it works on local computer time... (Being in +12 gmt I find that rollover is around 4pm... yeah, so my...
  4. N

    Alternate Trade Response Script

    Yeah before anyone says anything... I know its messy++... but anyway... Anyone trying to read and understand this script better have some sort of pain killers for the massive headache your bound to get =P. Currently Supports: (Assuming I didn't break it while doing some editing. after my last...
  5. N

    trade response script Version 2, fixed and working.

    Re: trade response script A quick fix of your script is after the first edits to count, this section: count = count + 1; } //the next while loop uses count to know how many items to handle, but Change it to, count = count + 1; } int TotItems = count-1; //the next while loop uses count to...
  6. N

    trade response script Version 2, fixed and working.

    Re: trade response script Yay my function got added! (Yes my function... well very similar to it anyway... of course you probably came up with it earlier then I did... *sigh*) Linky: http://kolmafia.us/index.php/topic,451.msg2376.html#msg2376 Oh and my trade script is almost ready for public...
  7. N

    Recommendations for this map

    In my own equipment map I'm using a huge single map of stats and a single less huge reference map. float [ item, string] EquipmentDatabase_Stats; item [ slot, int] EquipmentDatabase_Reference; The string in the stats map defines what the float value is for and the reference just helps me get the...
  8. N

    Manual Item Quant Editing

    Personally I ment in response to a trade so I'm using cli_execute( "URL") rather then visit_url as I have no intention of keeping the output string. Although I just realised, all I need to do is keep a int map with a single "item" key, I can simply add the number of "traded" items into the map...
  9. N

    Manual Item Quant Editing

    Is it currently possible for a script to manually alter the item quantities that mafia handles internally? I'm looking for this ability for my trade handler (Since if you offer up a item in trade, mafia wont recognise that the item is gone until you do a inventory refresh which would need to be...
  10. N

    Request: Index out of bounds error message

    I personally wouldn't mind even if it was just "Substring value error" or atleast something that tells the person its the substring function thats causing mafia to error out. (You can pick that out from the debug log but I take most people take a look at the first few lines of what it prints and...
  11. N

    Request: Index out of bounds error message

    I back this request! Although my debug log auto-opened and I took a look at the error in there and automatically knew what was wrong, I might just be weird =P. But anyway, yeah a error in the GCLI would be nice =D.
  12. N

    Message Extraction

    Yay no more using int MeatGain( string Message) { if( contains_text( Message, "<td valign=center>You gain ")) { int MeatGainStart = index_of( Message, "<td valign=center>You gain ")+27; int MeatGainEnd = index_of( Message, " Meat.", MeatGainStart); int MeatGain = string_to_int( substring(...
  13. N

    Re: ensure()

    Re: ensure() I was under the impression that "Acquire" already factors in currently existing items in your inventory. Unless I'm reading your request wrong... (Or I don't understand how acquire works...) Edit: I just tested with meat paste, and it seems acquire does already factor in existing...
  14. N

    trade response script Version 2, fixed and working.

    Re: trade response script Hey cool. I'm working on my own trade response script at the moment and looking at this, I really need to learn how to use "record" xD. (Currently mine just contains a mass of maps and is messy++) Edit: Some of the mess is from my ItemDesc finding (Before I actually...
  15. N

    Helper Script

    Hmm true if it can be used directly from the GCLI it's probably session based (I doubt it would be "permanent setting until enabled manually" since that would end up with a heap of bug reports saying "x function" isn't working when they happened to disable it a few days ago and forgot... but...
  16. N

    Daily Script

    I assume anything that doesn't end with ".ash", mafia will assume it is a CLI script. (Figured most people would be using .txt since it would be default for their text editor instead of making a new entry for something like ".cli") Uhh what ash command for what heal? You can probably use the...
  17. N

    Helper Script

    Uhh in the last example, by your "else" stick a "}" before it and a "{" after it. PS. Whats the return for? (in the drink one)
  18. N

    Helper Script

    If your going to use "else" while using "{" and "}" if( condition) { } else { } Edit: But if your sticking it in void main, doesn't that make it automatically assume enabled unless told otherwise? Or do the disable settings carry on even after the scripts ended?
  19. N

    Daily Script

    Uhh I said use a CLI script. Not use more cli_execute. send # meat to Buffbot send # meat to Buffbot send # meat to Buffbot send # meat to Buffbot send # meat to Buffbot wait 60 acquire 1 enchanted bean burrito acquire 2 hell ramen eat 2 hell ramen eat 1 enchanted bean burrito acquire 5 rockin'...
  20. N

    Helper Script

    If your going to use == then change the number to needs to equal to the same for each disable. Easier to remember "All 1 to disable all and all 0 to enable" rather than "The first 2 are 0 to disable and then the next 2 are 1 to disable".
Back
Top