//*************************************************************** // Copyright 2008 Centre For Advanced Spatial Analysis, UCL // // Author: Joel Dearden, University College London // // Contact: j.dearden@ucl.ac.uk // // Joel Dearden, // Centre for Advanced Spatial Analysis, // University College London, // 1-19 Torrington Place, // London, // WC1E 7HB // // // This file is part of SLPedEvac. // // SLPedEvac is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // // SLPedEvac is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with SLPedEvac. If not, see . // //*************************************************************** integer talkToBuildingComponents = -8927211; default { state_entry() { llListen(talkToBuildingComponents, "", NULL_KEY, ""); } on_rez(integer start_param) { //start param is y scale vector scale = llGetScale(); scale.y = start_param; llSetScale(scale); } listen(integer channel, string name, key id, string message) { if(channel == talkToBuildingComponents) { if(message == "demolish") { llDie(); } if(message == "REG") { vector pos = llGetPos(); rotation rot = llGetRot(); vector eulRot = llRot2Euler(rot); vector scale = llGetScale(); //NOTE: +ve X-axis points out of the front of a line barrier //send reset HTTP message llHTTPRequest( "
/input.aspx?f=rlb&px=" + (string)pos.x + "&py=" + (string)pos.y + "&pz=" + (string)pos.z + "&u=" + (string)llGetKey() + "&o=" + (string)eulRot.z + "&l=" + (string)scale.y, [], ""); llOwnerSay("registering"); } } } }