Add code that forces an error if compiled in LSO to all scripts

This should prevent accidents when saving in inventory in the official viewer.
This commit is contained in:
Sei Lisa 2018-05-18 00:28:02 +02:00 committed by Sei-Lisa
parent 9c84243390
commit f1ec6bde26
22 changed files with 46 additions and 32 deletions

View file

@ -24,7 +24,7 @@ integer notecard_section;
integer SCRIPT_CHANNEL; integer SCRIPT_CHANNEL;
string myPose; string myPose;
key mySitter; key mySitter;
list camera_triggers; list camera_triggers = [myPose]; //OSS::list camera_triggers; // Force error in LSO
list camera_settings; list camera_settings;
integer lastByButton = -1; integer lastByButton = -1;
string lastPose; string lastPose;
@ -109,6 +109,7 @@ default
state_entry() state_entry()
{ {
camera_triggers = [];
SCRIPT_CHANNEL = (integer)llGetSubString(llGetScriptName(), llSubStringIndex(llGetScriptName(), " "), 99999); SCRIPT_CHANNEL = (integer)llGetSubString(llGetScriptName(), llSubStringIndex(llGetScriptName(), " "), 99999);
notecard_key = llGetInventoryKey(notecard_name); notecard_key = llGetInventoryKey(notecard_name);
if (llGetInventoryType(notecard_name) == INVENTORY_NOTECARD) if (llGetInventoryType(notecard_name) == INVENTORY_NOTECARD)

View file

@ -19,6 +19,7 @@
integer COMM_CHANNEL = -57841689; integer COMM_CHANNEL = -57841689;
integer comm_handle; integer comm_handle;
list A = [comm_handle]; //OSS::list A; // Force error if not compiled in Mono
list findPrimsWithSubstring(string name) list findPrimsWithSubstring(string name)
{ {

View file

@ -77,7 +77,7 @@ integer COMM_CHANNEL = -57841689;
integer comm_handle; integer comm_handle;
key avatar; key avatar;
list links; list links;
list ring_prims; list ring_prims = [avatar]; //OSS::list ring_prims; // Force error if not compiled in Mono
integer all_poses = -2; // cache the position of the "*" if it exists, for performance integer all_poses = -2; // cache the position of the "*" if it exists, for performance
goChain(list new_links) goChain(list new_links)

View file

@ -27,7 +27,7 @@ list XCITE_TILT;
integer TIMER_DEFAULT = 30; integer TIMER_DEFAULT = 30;
string CURRENT_POSE; string CURRENT_POSE;
list TIMERS; list TIMERS;
list SITTERS; list SITTERS = [CURRENT_POSE]; //OSS::list SITTERS; // Force error if not compiled in Mono
integer DEBUG; integer DEBUG;
Out(integer level, string out) Out(integer level, string out)

View file

@ -27,7 +27,7 @@ key SLAVE;
string menu; string menu;
integer menuPage; integer menuPage;
list folderPath; list folderPath;
list folderOptions; list folderOptions = [menu]; //OSS::list folderOptions; // Force error in LSO
list folderNamesFullLength; list folderNamesFullLength;
list CLOTHING_LAYERS = ["gloves", "jacket", "pants", "shirt", "shoes", "skirt", "socks", "underpants", "undershirt", "", "", "", "", "alpha", "tattoo"]; list CLOTHING_LAYERS = ["gloves", "jacket", "pants", "shirt", "shoes", "skirt", "socks", "underpants", "undershirt", "", "", "", "", "alpha", "tattoo"];
list ATTACHMENT_POINTS = ["", "chest", "skull", "left shoulder", "right shoulder", "left hand", "right hand", "left foot", "right foot", "spine", "pelvis", "mouth", "chin", "left ear", "right ear", "left eyeball", "right eyeball", "nose", "r upper arm", "r forearm", "l upper arm", "l forearm", "right hip", "r upper leg", "r lower leg", "left hip", "l upper leg", "l lower leg", "stomach", "left pec", "right pec", "", "", "", "", "", "", "", "", "neck", "root"]; list ATTACHMENT_POINTS = ["", "chest", "skull", "left shoulder", "right shoulder", "left hand", "right hand", "left foot", "right foot", "spine", "pelvis", "mouth", "chin", "left ear", "right ear", "left eyeball", "right eyeball", "nose", "r upper arm", "r forearm", "l upper arm", "l forearm", "right hip", "r upper leg", "r lower leg", "left hip", "l upper leg", "l lower leg", "stomach", "left pec", "right pec", "", "", "", "", "", "", "", "", "neck", "root"];

View file

@ -49,7 +49,7 @@ integer SEARCHhandle;
integer CHECKhandle; integer CHECKhandle;
integer ASKROLEhandle; integer ASKROLEhandle;
list DETECTED_AVATAR_SHORTNAMES; list DETECTED_AVATAR_SHORTNAMES;
list DETECTED_AVATAR_KEYS; list DETECTED_AVATAR_KEYS = [WAITPOSE]; //OSS::list DETECTED_AVATAR_KEYS; // Force error in LSO
integer awaiting_results; integer awaiting_results;
string baseCaptureRestrictions = "@unsit=n"; string baseCaptureRestrictions = "@unsit=n";
string baseReleaseRestrictions = "@unsit=force"; string baseReleaseRestrictions = "@unsit=force";

View file

@ -22,7 +22,7 @@ list DESIGNATIONS_NOW;
key CONTROLLER = NULL_KEY; key CONTROLLER = NULL_KEY;
integer KEY_TAKEN; integer KEY_TAKEN;
string CONTROLLER_NAME; string CONTROLLER_NAME;
list SITTERS_MENUKEYS; list SITTERS_MENUKEYS = [CONTROLLER_NAME]; //OSS::list SITTERS_MENUKEYS; // Force error in LSO
list SITTERS_SHORTNAMES; list SITTERS_SHORTNAMES;
integer menu_channel; integer menu_channel;
integer menu_handle; integer menu_handle;

View file

@ -57,7 +57,7 @@ list anim_animsequences;
list running_uuid; list running_uuid;
list running_sequence_indexes; list running_sequence_indexes;
list running_pointers; list running_pointers;
list SITTERS; list SITTERS = [key_request]; //OSS::list SITTERS; // Force error in LSO
list SITTER_POSES; list SITTER_POSES;
integer get_number_of_scripts() integer get_number_of_scripts()

View file

@ -29,7 +29,7 @@ string last_menu_avatar;
integer menu_channel; integer menu_channel;
key notecard_key; key notecard_key;
key notecard_query; key notecard_query;
list MENU_LIST; list MENU_LIST = [custom_text]; //OSS::list MENU_LIST; // Force error in LSO
list DATA_LIST; list DATA_LIST;
integer MTYPE; integer MTYPE;
integer LMSOURCE = 0; //lmsource self = 0, lmsource linkset = 1 integer LMSOURCE = 0; //lmsource self = 0, lmsource linkset = 1
@ -314,6 +314,7 @@ default
{ {
remove_script("Use only one copy of this script!"); remove_script("Use only one copy of this script!");
} }
MENU_LIST = [];
check_avsit(); check_avsit();
notecard_key = llGetInventoryKey(notecard_name); notecard_key = llGetInventoryKey(notecard_name);
Out(0, "Loading..."); Out(0, "Loading...");

View file

@ -25,6 +25,7 @@ integer experience_denied_reason;
key originalowner; key originalowner;
key parentkey; key parentkey;
key give_prop_warning_request; key give_prop_warning_request;
list A = [parentkey]; //OSS::list A; // Force error in LSO
unsit_all() unsit_all()
{ {
@ -90,7 +91,9 @@ state prop
} }
//LSL:: //LSL::
parentkey = llList2String(llGetObjectDetails(llGetKey(), [OBJECT_REZZER_KEY]), 0); parentkey = llList2String(llGetObjectDetails(llGetKey(), [OBJECT_REZZER_KEY]) + A, 0);
A = [];
if(llGetStartParameter() && !llList2Integer(llGetObjectDetails(parentkey, [OBJECT_ATTACHED_POINT]), 0)) if(llGetStartParameter() && !llList2Integer(llGetObjectDetails(parentkey, [OBJECT_ATTACHED_POINT]), 0))
{ {
llSetTimerEvent(10); llSetTimerEvent(10);

View file

@ -34,7 +34,7 @@ list prop_groups;
list prop_points; list prop_points;
list sequential_prop_groups; list sequential_prop_groups;
integer HAVENTNAGGED = TRUE; integer HAVENTNAGGED = TRUE;
list SITTERS; list SITTERS = [key_request]; //OSS::list SITTERS; // Force error in LSO
list SITTER_POSES; list SITTER_POSES;
list ATTACH_POINTS = list ATTACH_POINTS =
[ ATTACH_CHEST, "chest" [ ATTACH_CHEST, "chest"

View file

@ -28,7 +28,7 @@ list SEQUENCE_DATA_ACTIONS;
list SEQUENCE_DATA_DATAS; list SEQUENCE_DATA_DATAS;
string CURRENT_SEQUENCE_NAME; string CURRENT_SEQUENCE_NAME;
list CURRENT_SEQUENCE_ACTIONS; list CURRENT_SEQUENCE_ACTIONS;
list CURRENT_SEQUENCE_DATAS; list CURRENT_SEQUENCE_DATAS = [CURRENT_SEQUENCE_NAME]; //OSS::list CURRENT_SEQUENCE_DATAS; // Force error in LSO
integer SEQUENCE_LINKNUMBER = 90210; integer SEQUENCE_LINKNUMBER = 90210;
integer SEQUENCE_POINTER = -1; integer SEQUENCE_POINTER = -1;
integer sequence_running; integer sequence_running;

View file

@ -17,9 +17,9 @@
string product = "AVsitter2 MLP converter"; string product = "AVsitter2 MLP converter";
string version = "2.2"; string version = "2.2";
string notecard_basename = "AVpos"; string notecard_basename = "AVpos";
list NOTECARDS;
list PROPS_NOTECARDS;
string notecard_name; string notecard_name;
list NOTECARDS = [notecard_name]; //OSS::list NOTECARDS; // Force error in LSO
list PROPS_NOTECARDS;
key notecard_query; key notecard_query;
integer notecard_line; integer notecard_line;
integer notecard_pointer; integer notecard_pointer;
@ -98,6 +98,7 @@ default
{ {
Out(0, "Reading MLP notecards..."); Out(0, "Reading MLP notecards...");
Readout_Say(" "); Readout_Say(" ");
NOTECARDS = [];
get_notecards(); get_notecards();
if (llGetListLength(NOTECARDS) > 0) if (llGetListLength(NOTECARDS) > 0)
{ {

View file

@ -17,7 +17,7 @@
string notecard_basename = "AVpos"; string notecard_basename = "AVpos";
integer variable1; integer variable1;
key notecard_query; key notecard_query;
list ALL_USED_ANIMS; list ALL_USED_ANIMS = [notecard_query]; //OSS::list ALL_USED_ANIMS; // Force error in LSO
list UNUSED_ANIMS; list UNUSED_ANIMS;
integer NOT_FOUND_COUNT; integer NOT_FOUND_COUNT;
integer IS_VARIABLE_SPEED_SUBMENU; integer IS_VARIABLE_SPEED_SUBMENU;
@ -43,6 +43,7 @@ default
{ {
state_entry() state_entry()
{ {
ALL_USED_ANIMS = [];
if (llGetInventoryType(notecard_basename) == INVENTORY_NOTECARD) if (llGetInventoryType(notecard_basename) == INVENTORY_NOTECARD)
{ {
Owner_Say(" "); Owner_Say(" ");

View file

@ -16,10 +16,9 @@
/* /*
* Things not implemented: * Things not implemented:
* ~ perms of the object
* ~ creator of the object * ~ creator of the object
* ~ which platform/world (OpenSim/SL) * ~ which platform/world (OpenSim/SL) and version
*/ */
integer sendToSupport=FALSE; integer sendToSupport=FALSE;
integer sendItems = TRUE; integer sendItems = TRUE;

View file

@ -44,7 +44,7 @@ integer adding_item_type;
string last_text; string last_text;
integer menu_pages; integer menu_pages;
integer number_per_page = 9; integer number_per_page = 9;
list chosen_animations; list chosen_animations = [last_text]; //OSS::list chosen_animations; // Force error in LSO
string cache; string cache;
string webkey; string webkey;
integer webcount; integer webcount;

View file

@ -30,6 +30,7 @@ vector default_size = <0.12,0.12,3.5>;
key key_request; key key_request;
vector my_pos; vector my_pos;
rotation my_rot; rotation my_rot;
list A = [CURRENT_AV]; // Force error in LSO //OSS::
stop_all_anims() stop_all_anims()
{ {
@ -70,7 +71,8 @@ set_text()
setup() setup()
{ {
alpha = llList2Float(llGetPrimitiveParams([PRIM_COLOR, 0]), 1); alpha = llList2Float(llGetPrimitiveParams([PRIM_COLOR, 0]), 1);
CURRENT_AV = ""; CURRENT_AV = llList2Key(A, 0); //OSS::CURRENT_AV = "";
A = []; //OSS::
vector size = default_size; vector size = default_size;
if (llGetCreator() != llGetInventoryCreator(llGetScriptName())) if (llGetCreator() != llGetInventoryCreator(llGetScriptName()))
{ {

View file

@ -24,10 +24,10 @@ integer active_script_channel;
integer menu_channel; integer menu_channel;
integer menu_handle; integer menu_handle;
list SIT_TYPES = ["ALL", "OWNER", "GROUP"]; list SIT_TYPES = ["ALL", "OWNER", "GROUP"];
list MENU_TYPES = ["ALL", "OWNER", "GROUP"];
integer SIT_INDEX; integer SIT_INDEX;
integer MENU_INDEX; integer MENU_INDEX;
string lastmenu; string lastmenu;
list MENU_TYPES = [lastmenu]; //OSS::list MENU_TYPES; // Force error in LSO
integer pass_security(key id, string context) integer pass_security(key id, string context)
{ {
@ -134,6 +134,7 @@ default
{ {
state_entry() state_entry()
{ {
MENU_TYPES = SIT_TYPES;
llMessageLinked(LINK_SET, 90202, (string)check_for_RLV(), ""); llMessageLinked(LINK_SET, 90202, (string)check_for_RLV(), "");
} }

View file

@ -16,6 +16,8 @@
string script_basename = "[AV]sitA"; string script_basename = "[AV]sitA";
string menu_script = "[AV]menu"; string menu_script = "[AV]menu";
key A;
list B = [A]; //OSS::list B; // Force error in LSO
default default
{ {
@ -23,7 +25,8 @@ default
{ {
if (llGetInventoryType(script_basename) != INVENTORY_SCRIPT && llGetInventoryType(menu_script) != INVENTORY_SCRIPT) if (llGetInventoryType(script_basename) != INVENTORY_SCRIPT && llGetInventoryType(menu_script) != INVENTORY_SCRIPT)
{ {
llMessageLinked(LINK_ALL_OTHERS, 90005, "", llDetectedKey(0)); llMessageLinked(LINK_ALL_OTHERS, 90005, llList2String(B, 0), llDetectedKey(0));
B = [];
} }
} }
} }

View file

@ -27,7 +27,7 @@ string adjust_script = "[AV]adjuster";
string helper_object = "[AV]helper"; string helper_object = "[AV]helper";
string CUSTOM_TEXT; string CUSTOM_TEXT;
list SITTERS; list SITTERS;
list SYNCS; list SYNCS = [CUSTOM_TEXT]; //OSS::list SYNCS; // Force error in LSO
integer menu_channel; integer menu_channel;
integer menu_handle; integer menu_handle;
integer menu_type; integer menu_type;
@ -97,6 +97,7 @@ default
menu_handle = llListen(menu_channel, "", "", ""); menu_handle = llListen(menu_channel, "", "", "");
llListenControl(menu_handle, FALSE); llListenControl(menu_handle, FALSE);
integer i; integer i;
SYNCS = [];
for (i = 0; i < get_number_of_scripts(); i++) for (i = 0; i < get_number_of_scripts(); i++)
{ {
SITTERS += NULL_KEY; SITTERS += NULL_KEY;

View file

@ -27,7 +27,6 @@ list SITTERS;
integer SWAPPED; integer SWAPPED;
key MY_SITTER; key MY_SITTER;
key CONTROLLER; key CONTROLLER;
list SITTER_INFO;
string CUSTOM_TEXT; string CUSTOM_TEXT;
list ADJUST_MENU; list ADJUST_MENU;
integer SET = -1; integer SET = -1;
@ -51,6 +50,7 @@ string FIRST_MALE_ANIMATION_SEQUENCE;
string FEMALE_POSENAME; string FEMALE_POSENAME;
string FIRST_FEMALE_ANIMATION_SEQUENCE; string FIRST_FEMALE_ANIMATION_SEQUENCE;
string CURRENT_ANIMATION_FILENAME; string CURRENT_ANIMATION_FILENAME;
list SITTER_INFO = [FIRST_POSENAME]; //OSS::list SITTER_INFO; // Force error in LSO
integer SEQUENCE_POINTER; integer SEQUENCE_POINTER;
vector FIRST_POSITION; vector FIRST_POSITION;
vector FIRST_ROTATION; vector FIRST_ROTATION;

View file

@ -33,7 +33,7 @@ string ADJUST_MENU;
string SITTER_INFO; string SITTER_INFO;
list MENU_LIST; list MENU_LIST;
list DATA_LIST; list DATA_LIST;
list POS_ROT_LIST; list POS_ROT_LIST = [CUSTOM_TEXT]; //OSS::list POS_ROT_LIST; // Force error in LSO
integer helper_mode; integer helper_mode;
integer has_RLV; integer has_RLV;
integer ANIM_INDEX; integer ANIM_INDEX;