Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - DPeterson

Pages: [1]
1
Script Debug / Re: SUOLootSub
« on: December 08, 2011, 07:53:23 AM »
Well but what is the purpose of this? I mean, you could use set, with even taking less space than with namespaces ( AND DO THE SAME THING!!!! )

camotbik, but without namespaces if you tried to use another persons sub in your script, you'd have to go through their code and make sure you both didn't use any of the same variables...  when you write subs for others to use, if you use a namespace to encapsulate  your code in the sub, and return your result, other's don't have to worry about your code, it's just drag and drop with your own code.  Even if it uses the exact same variables they wont interfere with each other.

2
Script Debug / Re: SUOLootSub
« on: December 07, 2011, 04:21:07 AM »
Ok, just wondering, could you give me an example for something i could not do with out namespaces working in a 1window script?

This is about the best example I could envision.  Notice I set the !var to blue inside the namespace.  But on the other side of the namespace the !var still shows as green.  That's what namespaces are for. ;)

Code: [Select]
set !var green

namespace push
namespace local !var
set !var blue
namespace pop

event sysmessage !var
halt

3
Script Debug / Re: The MultiFlute 0.5
« on: November 26, 2011, 01:15:28 PM »
Here's a bit of code to get ya moving in the right direction so you don't have to target your flutes every time.
The Idea is not bad, what i miss, why only flutes? what is with my regular slayer tools?

It is probably in the other part of my script where I scan for other slayers.  I only posted the flute part to give him help.  Also, heres a handy way to organize all your spawn into types for ease of use later.  Will allow you to scan by slayer type, slayer difficulty, non slayer, and all spawn.  Very helpfull when looking for monsters for provoking.

Code: [Select]
  set !people
  set !forms
  set !summons

  set !nonSlayer1 yab_p_ki_ud_qd_vgb_n_pe_se_to_po_rb_ub ; easy non spell
  set !nonSlayer2 uc_mc_md_je                            ; easy spell
  set !nonSlayer3 db_kqb                                 ; medium non spell
  set !nonSlayer4 r_eb_wd_fd                             ; medium spell
  set !nonSlayer5 is_me_dd_bd_ej_ed_ri_cj_i              ; hard
  for !do 5 1
  {
    if !do = 5
      set !allNonSlayers !nonSlayer5
    else
      set !allNonSlayers !allNonslayers , _ , !nonSlayer . !do
  }
 
  ; Arachnid Slayer
  set !11 empty
  set !12 empty
  set !13 empty
  set !14 empty
  set !15 empty
  ; Elemental Slayer
  set !21 empty
  set !22 empty
  set !23 empty
  set !24 empty
  set !25 dd_bd_ej_ed_ri_cj
  ; Demon Slayer
  set !31 empty
  set !32 uc
  set !33 empty
  set !34 fd
  set !35 me
  ; Reptile Slayer
  set !41 empty
  set !42 empty
  set !43 empty
  set !44 empty
  set !45 empty
  ; Repond Slayer
  set !51 empty
  set !52 empty
  set !53 empty
  set !54 empty
  set !55 is     ; human
  ; Undead Slayer
  set !61 empty
  set !62 empty
  set !63 empty
  set !64 r_eb_wd  ; lichlord,lichlord
  set !65 empty
 
  for !do 1 6
  {
    for !it 5 1
    {
      if !do = 1 && !it = 5
        set !allSpawn !15
      else
      {
        set !combo !do , !it
        set !allSpawn !allSpawn , _ , ! . !combo
      }
      if !it = 5
      {
        set !combo !do , !it
        set ! . !do ! . !combo
      }
      else
      {
        set !combo !do , !it
        set ! . !do ! . !do , _ , ! . !combo
      }
    }
  }

4
New member introductions / Re: Hi.
« on: November 26, 2011, 09:18:54 AM »
Thanks guys.  Yes scripting is fun.

5
Script Debug / Re: The MultiFlute 0.5
« on: November 26, 2011, 09:16:57 AM »
Here's a bit of code to get ya moving in the right direction so you don't have to target your flutes every time.

Code: [Select]
  finditem PGP c_ , #backpackid
  for #findindex 1 #findcnt
  {
     event property #findid
     if arachnid in #property
       set !slayer1 #findid
     if elemental in #property
       set !slayer2 #findid
     if demon in #property
       set !slayer3 #findid
     if reptile in #property
       set !slayer4 #findid
     if repond in #property
       set !slayer5 #findid
     if undead in #property
       set !slayer6 #findid
  }

6
New member introductions / Hi.
« on: November 26, 2011, 08:29:43 AM »
  Hello.  I just read that I need to introduce myself, so here it goes.  I'm a shadow lurker that is starting to come into my own in the scripting department.  I thought I'd share a bit of scripting with a community, and others have talked about this site to me. 

  When I first started scripting there wasn't much in the way of "good" scripts to use.  I had to learn to rip them apart and assemble them to my own liking.  No matter how hard I tried I couldn't figure out how to actually script myself.  Then, one day, it just clicked.  And the rest is history.  I've been scripting ever since.  I can't stop!  It's been a long ride to get here, but it's great that cheffe still sees fit to update his old goat so that us users get to enjoy our passion still. 

I like to push the limits of what is ok scripting wise in the game.  What I mean is, I routinely run multiple miners to support my bod habit. I'm so bad.  Bods have always been my thing because they're so difficult to script extremely well.  Its great that some people have been so successfull at creating scripts to automate the process though.  I so much enjoy watching a great script tear through tons of bods. Anyways, I hope this is enough to get a small idea of who I am.  Thanks for the opportunity to be a part of the gang.  Look forward to meeting everyone.
  Dan

Pages: [1]