HOME PRODUCTS HELP FREEBIES SCRIPTS TUTORIALS NEWS CONTACT
  Teleport to Store in-world!    |     Links  
Main Menu
Alicia's Raffle
Who's Online
16 user(s) are online (2 user(s) are browsing Free Scripts)

Members: 0
Guests: 16

more...
Admin Login
Username:

Password:


Lost Password?

Register now!
SL Books


Sites of Interest
Published Date: 2010/5/12 0:25:16
Views : 173
Texture

Displays map image of current sim on prim & updates every 24 hours.


integer time = 86400; //update every 24 hours

key httpRequestId;
string mapTexture;
string URL = "http://www.subnova.com/secondlife/api/map.php";
 
default 
{
    on_rez( integer sparam )
    {
        llResetScript();
    }
    
    state_entry() 
    {
        llSetTimerEvent(time);
        httpRequestId = llHTTPRequest(URL + "?" + "sim" + "=" + llEscapeURL(llGetRegionName()),[], "");
    }
    
    http_response(key request_id, integer status, list metadata, string body)
    {
        if (request_id == httpRequestId) 
        {
            mapTexture = body;
            llSetTexture(mapTexture, ALL_SIDES); //you can replace ALL_SIDES with a side number instead
        }
    }
    
    timer() 
    {
        httpRequestId = llHTTPRequest(URL + "?" + "sim" + "=" + llEscapeURL(llGetRegionName()),[], "");
    }
}

0
|  Links 
Printer Friendly Page Send this Script to a Friend
Visit ASD Studios Hollywood
Product Spotlight
Alicia's Universe
Recent Scripts
Suggested Reading
Top Free Scripts

© 2006-2010 Alicia Stella | ASD Affiliate Programs | Policies | News | Help
Second Life®, Xstreet & the inSL logo are registered trademarks of Linden Research, Inc.
Alicia Stella Design is not affiliated with Second Life. No infringement is intended.