Jump to content

Leander Tyles

Resident
  • Posts

    75
  • Joined

  • Last visited

Posts posted by Leander Tyles

  1. 1)

    nobody needs 500 prims in an apartment which is already fully furnished.
    my tenants dont even reach that amount anyway this is just a safety precuation because i do get greifers sometimes.
    it is also more than 50% of the total prims i have available to me which is more then fair.
    the ban is only 24 hours, which is the equivalent to 2L per day if you cant go without a home for that long you need to reevaluate your life.
    most of my tenants live in my free homes so they dont pay nothing atall.

    2) this script is just more advance than everything else that is out thier, yes it does some policing but its main purpose it to keep the land clean

    3) i make barely any money atall im so cheap, as for going on a shopping spree and spending it thats a laugh i barely cover my tier

    4) i give the tenants the ability to refund themselfs if they decide to moveout, thats a good thing most people wouldnt

    5) i want others to use thier own time for free??? im sorry i guess i dont understand the purpose of the forum scripting section

    6) its almost a complete rewrite - your absolutly right... BY ME i take it you did read all the posts and didnt just glance at them

    7) i mentioned i have estate owner rights, im obviusly not new to the game, i said people still live in sandboxes

    8) thiers a age/time limit? before i must pay for advice thats obserd,
    im sure nobody else here is using these scripts to create products to resell on xstreet.. aint they running a buisiness too

    9) employment section, no thanks ill pass i wasted enough time camping back in the day, its time to enjoy myself

     

    a big thankyou 2 rolig, suggesting to use llownersay all over the place helped narrow down the problem area then i had to use my nogin to figure out why it was happening

     

    topic marked resolved

    goodbye

  2. i aint bothered to get into an arguement

    and i certainly dont know why you would agree with them, ive made every effort to solve the issues and shown examples along the way.

    i even said i figured out the problem and fixed it myself in the previous post,

    i even went so far to explain why it was occuring so other people could learn from it...

    but it looks like everyone overlooked that, ill go back and color it for you to make it easier to read.

     

    and yes i did come here for help origionally, i wrote quite alot of the script before i even approached the forums which suprisingly turned out better than expected because i didnt think i was upto the task so its not asif i expected people to do it for me.

     

    yes i have an old account surely my last name gave it away, infact i have much older ones than this but i still have no money at the end of the day doesnt matter how long ive been playing. thiere are people like me who still live in sandboxes

     

    you have an issue with me because i own a buisiness and i reach out for a little free help before resorting to hiring a scriptor..... well what can i say your correct yes im not a scriptor myself so i do need help from time to time... and i just needed to fix a few tiny bugs not create a project from scratch. infact scriptors usually shy away when it comes to modifying scripts even if you already done most of the work so these forums are usefull.

  3. i dont understand everyones issue, i have 937 prims, i temporery ban people if they use over 500??? thats more than half..we cant all afford our own plot of land us newbs must band together and all share a single plot to keep things affordable therefore thier must be rules.

     

    anyway the good news is i solved the puzzle.

      // AGENTS NOT IN THE SIM                          if (llListFindList(IsInSim,[llList2Key(prim_owners,x)]) == -1)                {                        // not in the sim, so queue for removal                    prim_interlopers+=llList2Key(prim_owners,x);                } 

     

    ### THIS IS WHAT I FOUND OUT ###

    basically lets say prim_owners is a list of all the parcelprimowners,

    then we remove my name from the list, then we run the code above,

    what if thier are no other names in the prim_owners list.....

    its checking/comparing the IsInSim list with BLANK ENTRYS from the prim_owners list,

    and its checking to ensure they not thier not in the sim so its bound to be true..

    ofcourse the blank entry isnt in the sim so it proceeds to update prim_interlopers

    and thats when it assigns a blank agentkey below.

    00000000-0000-0000-0000-000000000000

     

    so whats the fix? simples

     

                    if (prim_owners != [] && llListFindList(IsInSim,[llList2Key(prim_owners,x)]) == -1)

     

     

     

     

     

  4. unfortunatly made no difference, i almost gave up but i just made a discovery
    i know exactly what the problem is now... but i dont know what to do about it

     

    if (prim_interlopers!= []) // BOTH OF THESE LINES NEVER WORK
    if (llGetListLength(prim_interlopers) == 0) // BECAUSE THE LISTS NEVER BLANK IF DELETESUBLIST IS USED

     

    the problem is, if you use DELETESUBLIST, it replaces the entry with a null_key like

    00000000-0000-0000-0000-000000000000

     

    if i dont try to remove my name from the list and instead check prim_owner,x dont equal me in several places then

    it says "[THE JANITOR]: nothing to do, parcel is clear." as it should do

     

    it explains why the origional code didnt suffer from this problem since they didnt try to remove names from a list,

    if you do it still counts as 1 entry.... so im positive this is the issue here

     

  5. i see,

    the -4 makes sence because i wasnt granting it permission on purpose.

     

    the -3 however was from my script,

    considering it checks prim_interlopers!= [ ] before triggering the autoreturn, i dont see why it would suffer an invalid number problem

     

    which leads one to beleive my name aint realy removed from the list.

     

         timer()    {        // string toucher = llDetectedKey(0);                       // get list of prim owners on parcel            list prim_owners = llGetParcelPrimOwners(llGetPos());            list prim_interlopers=[];            integer x=0;                            // llReturnObjectsbyOwner wont return parcel owners prims but i remove my name from list for safety                integer idx;                if (~(idx = llListFindList(prim_owners,[llGetOwner()])))                 {  // strided lists                   prim_owners = llDeleteSubList(prim_owners,idx+1,idx+1); // remove primcount                    prim_owners = llDeleteSubList(prim_owners,idx,idx); // remove agent key                }             do {                                 list IsInSim = llGetAgentList(AGENT_LIST_REGION,[]);                                // AGENTS NOT IN THE SIM                if (llListFindList(IsInSim,[llList2Key(prim_owners,x)]) == -1)                {                        // not in the sim, so queue for removal                    prim_interlopers+=llList2Key(prim_owners,x);                }                                 // AGENTS STILL IN THE SIM                if (llListFindList(IsInSim,[llList2Key(prim_owners,x)]) != -1)                    {                        //llRegionSayTo(toucher,0,llList2String(prim_owners,x)+": "+llList2String(prim_owners,x+1)+" objects.");                                                // check to ensure they aint abusing prim limits?                                       if (llList2Integer(prim_owners,x+1) > PRIMLIMIT && llList2Integer(prim_owners,x+1) < PRIMABUSELIMIT )                         // should help prevent greifing attacks                        {                        prim_interlopers+=llList2Key(prim_owners,x); // queue for removal                        llInstantMessage(llList2Key(prim_owners,x),"[ALERT]: Im sorry we dont allow people to rez over 100 prims, your using " +llList2String(prim_owners,x+1)+ " you have 2 minutes to pick them up before they returned.");                        llSleep(120);                        }                    }                                        // if USING more than 500 prims ban them instantly for x hours                        if (llList2Integer(prim_owners,x+1) > PRIMABUSELIMIT)                         {                        prim_interlopers+=llList2Key(prim_owners,x); // queue for removal                        llAddToLandBanList(llList2Key(prim_owners,x),HOURS);                                                llRequestAgentData(mykey, DATA_NAME);                                                llInstantMessage(llList2Key(prim_owners,x),"[ALERT]: you are suspected of being a greifer by abusing prims and have been temporerily banned for " +(string)llRound(HOURS)+ " hours\nif you think this is a mistake please contact " +(string)prim_owner_name);                        llRequestAgentData(llList2Key(prim_owners,x), DATA_NAME);                                                llSay(0,"[ALERT]: " + (string)prim_owner_name + " has been temporerily banned for " +(string)llRound(HOURS)+ " hours on suspicion of greifing.");                        // regardless of notifyowner i want to be sure to recieve this wether im online or not                           llInstantMessage(llGetOwner(),"[ATTENTION]: " + (string)prim_owner_name + " has been temporerily banned for " +(string)llRound(HOURS)+ " hours on suspicion of greifing."); // state time of action                        }                                        x=x+2;               }            while(llGetListLength(prim_owners)>x);

    // ### IF I MOVE THE DELSUBLIST CODE TO HERE IT WORKS FINE ### // list empty, thiers no tasks to do so announce it to the world if (llGetListLength(prim_interlopers) == 0) { llSay(0,"[THE JANITOR]: nothing to do, parcel is clear."); } integer primcountreturned; // if we have prims to delete, do it. if (prim_interlopers!= []) { integer c; x=0; do { primcountreturned = primcountreturned + llList2Integer(prim_owners,x+1); c=llReturnObjectsByOwner(llList2Key(prim_interlopers,x),OBJECT_RETURN_PARCEL); if (NOTIFYOWNER == TRUE && prim_interlopers!= []) { // tells me the complete list of names and how many prims returned llInstantMessage(llGetOwner(),"returned "+(string)c+" prims owned by "+llList2String(prim_interlopers,x)); } x++; } while(llGetListLength(prim_interlopers)>x); } integer maxprims = (llGetParcelMaxPrims(llGetPos(), FALSE)); integer totalprimsused = (llGetParcelPrimCount(llGetPos(), PARCEL_COUNT_TOTAL, FALSE)); integer primsavailable = (maxprims - totalprimsused); if (llGetListLength(prim_interlopers) != 0) { // hopefully im not in lobby when this happens or i recieve multiple notifications llSay(0,"[THE JANITOR]: cleared up " +(string)primcountreturned+ " prims, thier are now " +(string)primsavailable+ " available."); } } }

     

    above i marked the area

    "// ### IF I MOVE THE DELETESUBLIST CODE TO HERE IT WORKS FINE ###"

    the only problem ofcourse is i need to remove my name at the beginning of the code not towards the end...

    because if im over the primlimit i get sent a warning message before we even reach that point.

     

    ive tried a few things to try and fix it

                    if (llListFindList(prim_owners,[llGetOwner()]) == -1)
                    {


    also

     

    if (prim_owners,x != llGetOwner())

    {

    //carry on with all the rest of the code

     

    but i cant get it to work the way i want so i think im gonna go ahead and do it the easy way because its getting on my nerves now

     

     if (llList2Integer(prim_owners,x+1) > PRIMABUSELIMIT && llList2Integer(prim_owners,x != llGetOwner())) 

     

     

     

     

     

     

     

     

  6. yes

     

    another problem i got is, i tried running the script every 60 seconds and i get

     

     Object: returned -3 prims owned by 00000000-0000-0000-0000-000000000000
    [15:15]  Object: [THE JANITOR]: cleared up 0 prims, thier are now 660 available.


    ^ it shouldnt say that atall since the list is empty,

    it should be saying "[THE JANITOR]: nothing to do, parcel is clear.""

     

    i have no idea why it says thiers negative prims, i modified another script from google to test if it had the same issue

     

    // list of people's prims to keep (owner UUIDs)list do_not_return =[    "6a5aef83-93a6-42e1-9d76-bd03b4f5e8aa",  // Darien Caldwell    "c3861ff5-b4a1-43e0-b76d-ed3189472577",  // Elizabeth Ivory    "e32c9042-57e2-4f19-b430-73494d11ceb8"   // Kat Fetisov];// list of people who can trigger a cleanup (return)// doesn't have to be the same as above, but probably will belist allowed_to_trigger_return =[    "6a5aef83-93a6-42e1-9d76-bd03b4f5e8aa",  // Darien Caldwell    "b91d12f1-4e0f-4752-8199-73d71fdeeee5"   // Lucia Nightfire];default{    state_entry()    {        llSetTimerEvent(60);        llRequestPermissions(llGetOwner(),PERMISSION_RETURN_OBJECTS);    }        on_rez(integer param)    {        llRequestPermissions(llGetOwner(),PERMISSION_RETURN_OBJECTS);    }        run_time_permissions(integer perm)    {        if (perm & PERMISSION_RETURN_OBJECTS)        {            llOwnerSay("Permission Granted, ready to return stuff!");        }    }        timer()    {            // get list of prim owners on parcel            list prim_owners = llGetParcelPrimOwners(llGetPos());            list prim_interlopers=[];            integer x=0;                          do {                if (llListFindList(do_not_return,[llList2String(prim_owners,x)]) == -1)                {                    llOwnerSay(llList2String(prim_owners,x)+" was not found so adding to delete list");                    // not on the keep list, so queue for removal                    prim_interlopers+=llList2Key(prim_owners,x);                }                x=x+2;                        }            while(llGetListLength(prim_owners)>x);                        // if we have prims to delete, do it.            if (prim_interlopers!= [])            {                integer c;                x=0;                do {                    c=llReturnObjectsByOwner(llList2Key(prim_interlopers,x),OBJECT_RETURN_PARCEL);                    llOwnerSay("returned "+(string)c+" prims owned by "+llList2String(prim_interlopers,x));                    x++;                }                while(llGetListLength(prim_interlopers)>x);            }                    }    }

     this one does it too however it claims i got -4 prims

    [15:18]  Object: returned -4 prims owned by 931e6dc3-5a81-4bde-acaf-28abdd6ead45

     

    i dont understand what the issue is, or why it would report different infomation when im running them at the sametime.

    the script works fine and none of this would be an issue if i didnt want it to talk on public chat.. but i do hmm

     

    ofcourse i could check its not a negative number before talking in public-chat but thats kinda cheating

     

  7. ok thanks i beleive i got it now, i delete the prims first then the key or i can just remove idx twice, same thing

     

    prim_owners = llDeleteSubList(prim_owners,idx+1,idx+1);prim_owners = llDeleteSubList(prim_owners,idx,idx); 

     

    i also done the reporting to public

     

                     primcountreturned = primcountreturned + llList2Integer(prim_owners,x+1);              llReturnObjectsbyOwner(llList2Key(prim_interlopers,x),OBJECT_RETURN_PARCEL);                    x++;                }                while(llGetListLength(prim_interlopers)>x);            }            llOwnerSay("[THE JANITOR]: total prims cleared up " +(string)primcountreturned+ " objects.");

     

    updated a little

     

                integer maxprims = (llGetParcelMaxPrims(llGetPos(), FALSE));            integer totalprimsused = (llGetParcelPrimCount(llGetPos(), PARCEL_COUNT_TOTAL, FALSE));            integer primsavailable = (maxprims - totalprimsused);                        llOwnerSay("[THE JANITOR]: cleared up " +(string)primcountreturned+ " prims, thier are now " +(primsavailable)+ " available.");

     

  8. understood,


    maybe i should have mentioned i aint offering luxury homes here, my skyboxes are free.

    they dont come with prims.... the ability to rez items and change outfits is a privilege.

     

    if one person abuses the primlimit, everybody else is effected & i dont mean they cant rez items,

    i mean they have no home to goto in that case, because thiers no prims free to rez a home.

     

    1 single person can ruin it for everybody - if i wasnt around to watch over them all these years

     

    also these numbers are just variables,  i do moniter aboutland and see the average prims people tend to use.

     

    the whole point of this script is so my buissness is automated and i dont have to play constantly anymore.

     

    why did i have to play constantly?

     

    sure i could have disabled all residents can create objects -but whats the point of a home where you cant rez items.. it doesnt realy feel like your own then.

     

    and thiers always tenants which dont follow the rules and will try to get around the autoreturn timer by setting prims to the group - the land aint deeded so i am the only one who can clean up several times a day everyday

     

    from my experience its actually old players not newbs which try to use up all the prims...

    not because they dont know any better but because they want to take advantage i see it all the time and not just at my own rentals/dressing rooms - thier are some places which charge as low as 10L per week for 0 prims and people still help themselfs to hundreds of prims which is the equivalent of renting an expensive 512sqm of land

     

    also greifers aint always smart enough to wear the grouptag when rezzing a item which spreads like a virus - so after  along period of time thier is a small chance it can clears itself up but very unlikely

     

    but now thanks to llReturnObjectsbyOwner


    * i can allow all residents to use scripts not just the group

    * i dont need to use the lands autoreturn atall, instead of 40minute return time.... i only return if they nolonger in the sim

     

    i think its all for the best

     

    btw i figured out how to remove my name from the list which seems to work, but i still have issues

                    integer idx;                if (~(idx = llListFindList(prim_owners,[llGetOwner()])))                 {                   prim_owners = llDeleteSubList(prim_owners,idx,idx);                 }

     

    ive played around with it to ensure it does remove my name from the list, and i can confirm it does with the code below

     

    // AGENTS STILL IN THE SIM                if (llListFindList(IsInSim,[llList2Key(prim_owners,x)]) != -1)                    {                        llRegionSayTo(toucher,0,llList2String(prim_owners,x)+": "+llList2String(prim_owners,x+1)+" objects.");

     

    but heres my problem, if i use llownersay down below

    then it still reports my prims? but i dont understand why if i removed my name from the list at the very start.

     

    if im the only person with prims on the land it will say PARCEL IS CLEAR so the list is surely empty?

    but if another person has prims on my land.... im included in the list again for some reason

     

       while(llGetListLength(prim_owners)>x);                        // list empty, thiers no tasks to do so announce it to the world            if (llGetListLength(prim_interlopers) == 0)             {                llSay(0,"[THE JANITOR]: nothing to do, parcel is clear.");            }                        // if we have prims to delete, do it.            if (prim_interlopers!= [])            {                x=0;                do {                                        // llReturnObjectsbyOwner(llList2Key(prim_interlopers,x),OBJECT_RETURN_PARCEL);                    llOwnerSay("[THE JANITOR]: " + llList2String(prim_owners,x)+": "+llList2String(prim_owners,x+1)+" objects.");                    x++;                }                while(llGetListLength(prim_interlopers)>x);            }        }    }

     

    it says

    [THE JANITOR]: 931e6dc3-5a81-4bde-acaf-28abdd6ead45: 15 objects.
    [THE JANITOR]: 15: 371 objects.

    ^bit weird 15 is on the second line, also it still knows how many prims i have it shouldnt be saying 371 atall so i must be doing summit wrong with deleting the sublist

     

    when i figure this out, i would just like to report total amount of prims returned, not each individual persons amount

  9. updated script

     

    integer NOTIFYOWNER = TRUE;string prim_owner_name;integer KEEPPRIMSFREE = 100; // try to ensure thiers always prims free so a house can rezinteger PRIMABUSELIMIT = 500; // temporery ban people using over this amount of primsinteger PRIMLIMIT = 100; // prim allowance - return prims if tenant is using over this amountfloat   HOURS = 24.00; // float - ban duration if tenant abuses primskey mykey;integer primcheck() {    integer maxprims = llGetParcelMaxPrims(llGetPos(), FALSE);    integer totalprimsused = llGetParcelPrimCount(llGetPos(), PARCEL_COUNT_TOTAL, FALSE);        integer primcount = (maxprims - totalprimsused);    integer primshortage = (KEEPPRIMSFREE - primcount);        if (primcount >= KEEPPRIMSFREE) {        return TRUE;    }    return FALSE;}default{        dataserver(key queryid, string data)    {            prim_owner_name = data;         }        state_entry()    {        mykey = llGetOwner();        llRequestPermissions(llGetOwner(),PERMISSION_RETURN_OBJECTS);    }        on_rez(integer param)    {        llRequestPermissions(llGetOwner(),PERMISSION_RETURN_OBJECTS);    }        run_time_permissions(integer perm)    {        if (perm & PERMISSION_RETURN_OBJECTS)        {            llOwnerSay("Permission Granted, ready to return stuff!");        }    }        touch_start(integer total_number)    {        string toucher = llDetectedKey(0);                       // get list of prim owners on parcel            list prim_owners = llGetParcelPrimOwners(llGetPos());            list prim_interlopers=[];            integer x=0;                        do {                                 list IsInSim = llGetAgentList(AGENT_LIST_REGION,[]);                                // check thiers atleast 100 prims spare at all times to ensure thiers no house rezzing problems                if (primcheck() != TRUE)                 { // free up resources by returning everybodys with an explanation                    prim_interlopers+=llList2Key(prim_owners,x);                                         if (llListFindList(IsInSim,[llList2Key(prim_owners,x)]) != -1) // still in the sim                    {                    // notify any tenants in the sim about the situation                    llInstantMessage(llList2Key(prim_owners,x),"[bROADCAST]: thiers not many prims available at the moment so we are returning everybodys to free up resources.");                    }                }                                // AGENTS NOT IN THE SIM                if (llListFindList(IsInSim,[llList2Key(prim_owners,x)]) == -1)                {                    // not in the sim, so queue for removal                    prim_interlopers+=llList2Key(prim_owners,x);                }                                 // AGENTS STILL IN THE SIM                if (llListFindList(IsInSim,[llList2Key(prim_owners,x)]) != -1)                    {                        // check to ensure they aint abusing prim limits?                                       if (llList2Integer(prim_owners,x+1) > PRIMLIMIT && llList2Integer(prim_owners,x+1) < PRIMABUSELIMIT )                         // should help prevent greifing attacks                        {                        prim_interlopers+=llList2Key(prim_owners,x); // queue for removal                        llInstantMessage(llList2Key(prim_owners,x),"[ALERT]: Im sorry we dont allow people to rez over 100 prims, your using " +llList2String(prim_owners,x+1)+ " you have 2 minutes to pick them up before they returned.");                        llSleep(120);                        }                    }                                        // if USING more than 500 prims ban them instantly for x hours                        if (llList2Integer(prim_owners,x+1) > PRIMABUSELIMIT)                         {                        prim_interlopers+=llList2Key(prim_owners,x); // queue for removal                        llAddToLandBanList(llList2Key(prim_owners,x),HOURS*3600);                                                llRequestAgentData(mykey, DATA_NAME);                                                llInstantMessage(llList2Key(prim_owners,x),"[ALERT]: you are suspected of being a greifer by abusing prims and have been temporerily banned for " +(string)llRound(HOURS)+ " hours\nif you think this is a mistake please contact " +(string)prim_owner_name);                        llRequestAgentData(llList2Key(prim_owners,x), DATA_NAME);                                                llSay(0,"[ALERT]: " + (string)prim_owner_name + " has been temporerily banned for " +(string)llRound(HOURS)+ " hours on suspicion of greifing.");                        // regardless of notifyowner i want to be sure to recieve this wether im online or not                           llInstantMessage(llGetOwner(),"[ATTENTION]: " + (string)prim_owner_name + " has been temporerily banned for " +(string)llRound(HOURS)+ " hours on suspicion of greifing."); // state time of action                        }                                        x=x+2;               }            while(llGetListLength(prim_owners)>x);                        // if we have prims to delete, do it.            if (prim_interlopers!= [])            {                x=0;                do {                                     //   llReturnObjectsbyOwner(llList2Key(prim_interlopers,x),OBJECT_RETURN_PARCEL);                                    x++;                }                while(llGetListLength(prim_interlopers)>x);            }                    }    }// TODO LIST:// make notify owner work// remove owner from list// llRequestAgentData too slow to work// unable to warn owner once if thier was a primlimit situation - not important tho i suppose

     

  10. i havent made much progress, nothing new except for rewriting it because i couldnt figure out why it stopped functioning properly

    i want to remove my name from the list to avoid being told off for being over the prim limit.. since all the houses on the land belong to me it makes sence that im the one using up the most resources.

    i tried using llRequestAgentData but i got the same issue as before, its to slow to retreive the name so instead the message is just blank

    i also dont think thier was a problem, i probally got the NOTIFYOWNER msg in the wrongplace, but i cnt figure it out

    i assume a person with over 500 prims is a greifer because i only have 4096sqm, i dont have many prims so one individual certainly shouldnt be using that many especially when i offer fully furnished homes and use less than that myself.... but yes an innocent person may get harmed which is why the bans only temporery besides they're sent a warning if using more than 100 prims... so they shouldnt be rezzing more, i will make the script wait before taking action and possibly give the tenant 2 minutes to pick thier items up

     

  11. i decided to do things differently and wrote this script

    i have a few questions tho

     

    if im an estate manager, do i have to worry about llReturnObjectsbyOwner returning my neighbours prims?

    let me give you a scenario, what if a fellow landowner happens to have a prim on my land

    im concerned about my system not only removing the prim on my land but quite possibly all items from his own land.

     

    anyway moving on:

    no more moving sensors, no more limitations.

     

    after i retreive parcel prim owners, i check to ensure they nolonger in the sim before returning thier prims,

    even if the tenant is still in the sim if they using over 100 prims i immediatly return them and give em a warning,

    if over 500 prims then they banned for 24 hours

     

    whats left to do

     

    * when i get llGetParcelPrimOwners(llGetPos()); - how do i remove myself from the list

    * also if tenants use over 50 prims, how to only warn them once? since this code will be triggered every 30mins or so 
                           

    another problem i notice

    [10:37]  Object: [THE JANITOR]: 1 prims returned to
    [10:37]  Object: [THE JANITOR]: 0 prims returned to
    [10:37]  Object: [THE JANITOR]: 515 prims returned to Leander Tyles
    [10:37]  Object: [THE JANITOR]: 0 prims returned to

     

    its true i have 515 prims on my land, another person has 1 ... but why doesnt it say thier name above ^?

    the other two people have 2 and 16 prims on the land, but as you can see above it says 0

     

    so i dont know what the problem is? im guessing the names dont show because they aint in the sim perhaps, kinda screws up my notification msg blah

     

    // NOTE2SELF use a timer
    
    integer NOTIFYOWNER = TRUE;
    
    default
    {
            state_entry()
            {
                llRequestPermissions(llGetOwner(),PERMISSION_RETURN_OBJECTS);
            }
           
            on_rez(integer param)
            {
                llRequestPermissions(llGetOwner(),PERMISSION_RETURN_OBJECTS);
            }
           
            run_time_permissions(integer perm)
            {
                if (perm & PERMISSION_RETURN_OBJECTS)
                {
                    llOwnerSay("Permission Granted, ready to return stuff!");
                }
            }
                
        touch_start(integer total_number)
        {
    
                    list prim_owners = llGetParcelPrimOwners(llGetPos());
                    list prim_interlopers=[];
                    integer x=0;
    
                    do {
                        list IsInSim = llGetAgentList(AGENT_LIST_REGION,[]);
    
                        if (llListFindList(IsInSim,[llList2Key(prim_owners,x)]) == -1)
                        {
                            // not in the sim, so queue for removal
                            prim_interlopers+=llList2Key(prim_owners,x);
                        }
                            
                            // it would be nice to warn people when they go over 50, problem is i dont wanna risk
                            // spamming them with warnings every time this script is triggered
                            
                        if (llListFindList(IsInSim,[llList2Key(prim_owners,x)]) != -1)
                        {
                            // they still in the sim, check to ensure they aint abusing prim limits?
                            
                            if (llList2Integer(prim_owners,x+1) > 100 && llList2Integer(prim_owners,x+1) < 500 ) 
                            // should help prevent greifing attacks
                            {
                            prim_interlopers+=llList2Key(prim_owners,x); // queue for removal
                            llInstantMessage(llList2Key(prim_owners,x),"[ALERT]: Im sorry we dont allow people to rez over 100 prims, your using " +llList2String(prim_owners,x+1)+ " we have to return them.");
                            }
                            // if more than 500 ban them for 24 hours
                            if (llList2Integer(prim_owners,x+1) > 500)
                            {
                            prim_interlopers+=llList2Key(prim_owners,x); // queue for removal
                            llAddToLandBanList(llList2Key(prim_owners,x),24.0); // temp ban for 24 hours
                            llInstantMessage(llList2Key(prim_owners,x),"[ALERT]: you are suspected of being a greifer by abusing prims and have been temporerily banned for 24 hours\nif you think this is a mistake please contact " +llKey2Name(llGetOwner()));
                            llSay(0,"[ALERT]: " + llKey2Name(llList2String(prim_owners,x)) + " has been temporerily banned for 24 hours on suspicion of greifing.");
                            // regardless of notifyowner i want to be sure to recieve this wether im online or not   
                            llInstantMessage(llGetOwner(),"[ALERT]: " + llKey2Name(llList2String(prim_owners,x)) + " has been temporerily banned for 24 hours on suspicion of greifing.");
                            }
                        }
                        x=x+2;            
                    }                
                    
                    while(llGetListLength(prim_owners)>x);
                   
                    // if we have prims to delete, do it.
                    if (prim_interlopers!= [])
                    {
                        x=0;
                        do {
                     
                   if (NOTIFYOWNER == TRUE)
                   {
                   // notify owner whos prims are being returned + how many
                   // if over 100 i have to presume they have been warned by the system and forcefully removed, not left sim.
                   llOwnerSay("[THE JANITOR]: " + (string)llList2Integer(prim_owners,x+1) + " prims returned to " + llKey2Name(llList2String(prim_owners,x)));  
                   }
                          
                   //   llReturnObjectsbyOwner(llList2Key(prim_interlopers,x),OBJECT_RETURN_PARCEL);
                            x++;
                        }
                        while(llGetListLength(prim_interlopers)>x);
                    }
                   
                }
    }

     

  12. wasnt sure how to merge the code together so i done it like this hopefully correct, not tested

    could have possibly used lDetectedType(i) aswell

     

       sensor(integer num)    {                list SendHome;        integer i;        while (i< num)        {            list temp = llGetObjectDetails(llDetectedKey(i),[OBJECT_OWNER]);                        if (llGetAgentSize(llDetectedKey(i)) == ZERO_VECTOR)              {             Move();   // this is an avatar so lets move            }            if (llList2Key(temp,0) != gOwnerKey && llGetAgentSize(llDetectedKey(i)) == ZERO_VECTOR && llOverMyLand(llDetectedKey(i)) == TRUE)                llRegionSayTo(llGetOwner(),0,"WOULD BE RETURNING " + (string)llDetectedName(i));                SendHome += [llDetectedKey(i)];            }            ++i;        }         llReturnObjectsByID(SendHome);        if (gON == TRUE) { Move(); }    }

     

  13. thanks, understood

    a question regarding the sensor, im now scanning for agents and objects at the same time

     

    llSensor("","",AGENT|ACTIVE|PASSIVE, scanRange, PI);

     

    if an agent is detected i would like it to skip that area

     

    is it possible to determine wether the results happen to be an avatar?

     

    or am i going about it wrong, maybe i need to perform twice as many scans

    1) scan to ensure no avatars around

    2) then scan for junk/prims afterwards

     

    i allow people to rez items, i dont want to cleanup if they still thier

     

    actually now that i think of it, considering the limitations maybe scanning for agents only first is the best option

     

  14. thats too advanced for me, but my gadget scans from ground level upto the sky then takes a break

    even if it doesnt return all the prims on its first journey,

    since its configured to happen every hour it will clear them all up eventually


    happy days

     

    i dont think thiers anything wrong with the script i posted,

    just got to be brave enough to run it

    i performed a little test just to detect objects nearby which aint owned by me....

    its asif the filter does nothing because it still reports back to me a list of objects that i own

    but the good news is they aint being returned.

     

    thats what i dont understand o well

     

  15. Hello,

    after discovering this kewl new function in the other guys thread i tried making my own little gadget but im having a few problems


    i blanked out   // llReturnObjectsByID(SendHome);
     while testing it so i dont mess up

    and made it report back what item names it would be returning

    the problem is i reconise some of these item names in the list because I OWN THEM,

    which means they would have been returned to me... not good atall

    i dont think thiers a problem with the script tho?

    if (llList2Key(temp,0) != gCreatorKey && llOverMyLand(llDetectedKey(i)) == TRUE) 

    so whys this happening, what to do hmm

    integer minHeight = 0;
    integer maxHeight = 4000;
    integer increment = 96; // 41 ish scans
    integer scanRange = 96;
    float   waitTime = 1.0;
    
    integer gON;
    integer gOK;
    key gCreatorKey;
    
    vector gStartPos;
    integer gReturnToStartPos=TRUE;
    
    Warp(vector pos) {
        list rules;
        integer num = llRound(llVecDist(llGetPos(),pos)/10)+1;
        integer x;
        for(x=0; x<num; ++x) rules=(rules=[])+rules+[PRIM_POSITION,pos];
        llSetPrimitiveParams(rules);
    }
    
    Move() {
        llSleep(waitTime);
        vector pos = llGetPos();
        integer height = (integer)pos.z;
        integer newHeight = height + increment;
        
        if (height + increment >= maxHeight) {
           gON = FALSE; // turned off so stay still
           Warp(gStartPos); // back to starting position
           llSetAlpha(0.5, ALL_SIDES);
           llOwnerSay("OPERATION COMPLETE");     
    }
        
        if (gON == TRUE) {
        Warp(<pos.x, pos.y, newHeight>);
        llSensor("","",ACTIVE|PASSIVE, scanRange, PI);
    }
    }
    
    default {
        state_entry() {
           gCreatorKey = llGetOwner();
           llRequestPermissions(llGetOwner(),PERMISSION_RETURN_OBJECTS);
           llSetObjectName("PRIM SWEEPER");
           gStartPos = llGetPos();
           llOwnerSay("NOW STARTED: will scan every hour unless deactivated");
           llSetTimerEvent(3600); // perform routine every hour
        }
        
        run_time_permissions(integer perm)
        {
            if (perm & PERMISSION_RETURN_OBJECTS)
            {
                gOK = TRUE;
            }
        }
    
        timer() {
            llSensor("","",ACTIVE|PASSIVE, scanRange, PI); // lets begin
            gON = TRUE;
        }
    
        touch_start(integer total_number)
        {
            if (llGetOwner() == llDetectedKey(0))
            {
                if (gOK)
                {
                    gON = !gON; // pretty useless realy not asif i can stop it once its started, unless short interval break before start
                    llRegionSayTo(llDetectedKey(0),0,"Device switched " + llList2String(["OFF","ON"],gON) );
                    vector pos = llGetPos();
                    Warp(<pos.x, pos.y, minHeight>); // start at the floor / ground but stored in any starting place
                    llSetAlpha(0.0, ALL_SIDES); // totaly invisible
                    llSetStatus(STATUS_PHANTOM, TRUE); // phantom
                    llSensor("","",ACTIVE|PASSIVE, scanRange, PI); // lets begin
                    
                }
                else
                {
                    llRequestPermissions(llGetOwner(),PERMISSION_RETURN_OBJECTS);
                }
            }
        }
     
        changed(integer change)
        {
            if (change & CHANGED_OWNER)
                llResetScript();
        }
           
        sensor(integer num)
        {        
            list SendHome;
            integer i;
            while (i< num)
            {
                list temp = llGetObjectDetails(llDetectedKey(i),[OBJECT_CREATOR]);
                if (llList2Key(temp,0) != gCreatorKey && llOverMyLand(llDetectedKey(i)) == TRUE)  
                // Or substitute your favorite filter here
                // very important to ensure its over your land because if your an estate manager you`ll return neighbours items
                {
                    llRegionSayTo(llGetOwner(),0,"WOULD BE RETURNING " + (string)llDetectedName(i));
                    SendHome += [llDetectedKey(i)];
                }
                ++i;
            }
            //llReturnObjectsByID(SendHome);
            if (gON == TRUE) { Move(); }
        }
        
        no_sensor() {
             if (gON == TRUE) { Move(); }
        }
    }
    
    // my todolist
    // notify owner of number of prims returned to each individual
    // only additems to sendhome list if no avatar is detected during the scan

     

     infact i notice the other guys script does the same

  16. this problems is still plaguing me, ive been keeping record of the times it occurs

    09/18/2013  00:04:38
    09/18/2013  17:04:45

    i may have reset the script so slight difference

    09/29/2013     00:13:56     3eae60c0     Destination: CHUCKY100
    09/29/2013     17:14:05     9ea751fd     Destination: nickywgjr Giugiaro

    chucky is chosen on sunday, im online till like 1am in the morning.. it still says chucky before i goto sleep but by the time i awake it says nickywgjr so the lottery has taken place again !

    i used one of these scripts to findout the date in sl, some reason it said sunday

    http://wiki.secondlife.com/wiki/Day_of_the_Week

    [16:55]  Object: Today is Sunday.
    [16:55]  Object: Offset is -7.000000 hours.
    [16:55]  Object: It is currently daylight savings time.


    but when i looked at aboutland and checkout the time of the last rezzed prim, it says:

    mon sep 30  00:54:09 2013

    dont know if that has anything to do with it or not, eitherway shouldnt be triggering it to go off twice

  17.  

    integer getRefund(integer expiration)
    {
    integer cash = (((expiration - llGetUnixTime()) / 86400) * RENT_RATE / 7);
    return llRound(cash*0.8);
    }

    lets pretend the rents L$20 lindens per week,

    and thiers a 20% fee if a tenant decides to moveout.

    then they should be given back 16 lindens

    the problem is this script only returns 14 lindens

    so instead i have to resort to using:

    llRound(cash*0.8 + 2); // to make it work correctly

    but that complicates matters further because if the rental price was 30, then i would have to use:
    llRound(cash*0.8 + 3); // to work correctly

    i would like it to always work correctly

    no matter if i alter the price or the moveout fee without having to resort to editing the code, plz help

  18.  

    integer getRefund(integer expiration)
    {
    integer cash = (((expiration - llGetUnixTime()) / 86400) * RENT_RATE / 7);
    return llRound(cash*0.8);
    }

    lets pretend the rents L$20 lindens per week,

    and thiers a 20% fee if a tenant decides to moveout.

    then they should be given back 16 lindens

    the problem is this script only returns 14 lindens

    so instead i have to resort to using:

    llRound(cash*0.8 + 2); // to make it work correctly

    but that complicates matters further because if the rental price was 30, then i would have to use:
    llRound(cash*0.8 + 3); // to work correctly

    i would like it to always work correctly

    no matter if i alter the price or the moveout fee without having to resort to editing the code, plz help

×
×
  • Create New...