aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src/love
diff options
context:
space:
mode:
authorDavid Walter Seikel2014-05-16 10:36:07 +1000
committerDavid Walter Seikel2014-05-16 10:36:07 +1000
commit9c38f2289d544afc831f2825113bff4f87c73eb2 (patch)
tree175ce7b8e182efbd23611dc243865e27ca6a0653 /src/love
parentImplement llGetTime() and friends. (diff)
downloadSledjHamr-9c38f2289d544afc831f2825113bff4f87c73eb2.zip
SledjHamr-9c38f2289d544afc831f2825113bff4f87c73eb2.tar.gz
SledjHamr-9c38f2289d544afc831f2825113bff4f87c73eb2.tar.bz2
SledjHamr-9c38f2289d544afc831f2825113bff4f87c73eb2.tar.xz
Fake llKey2Name(), since there's only one user we know about at the moment.
Diffstat (limited to 'src/love')
-rw-r--r--src/love/love.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/love/love.c b/src/love/love.c
index 183e20e..113118c 100644
--- a/src/love/love.c
+++ b/src/love/love.c
@@ -319,6 +319,23 @@ static Eina_Bool _dataLuaSL(void *data, int type, Ecore_Con_Event_Server_Data *e
319 sendForth(ourGlobals->serverLuaSL, SID, "return \".POSITIONS\""); 319 sendForth(ourGlobals->serverLuaSL, SID, "return \".POSITIONS\"");
320 else if (0 == strcmp(command, "llGetInventoryName(7, 0)")) 320 else if (0 == strcmp(command, "llGetInventoryName(7, 0)"))
321 sendForth(ourGlobals->serverLuaSL, SID, "return \".MENUITEMS\""); 321 sendForth(ourGlobals->serverLuaSL, SID, "return \".MENUITEMS\"");
322 else if (0 == strncmp(command, "llKey2Name(", 11))
323 {
324 char *temp;
325
326 strcpy(buf, &command[12]);
327 temp = buf;
328 while (')' != temp[0])
329 temp++;
330 temp[0] = '\0';
331 if (0 == strcmp(buf, ownerKey))
332 temp = ownerName;
333 else
334 temp = "Unkown User";
335 // TODO - Sanitize the name, no telling what weird shit people put in their names.
336 snprintf(buf, sizeof(buf), "return \"%s\"", temp);
337 sendForth(ourGlobals->serverLuaSL, SID, buf);
338 }
322 // Send "back" stuff on to the one and only client. 339 // Send "back" stuff on to the one and only client.
323 // TODO - All of these output functions should just use one thing to append stuff to either local or an IM tab. 340 // TODO - All of these output functions should just use one thing to append stuff to either local or an IM tab.
324 // Love filtering out stuff that should not go there. 341 // Love filtering out stuff that should not go there.