Code Monkey home page Code Monkey logo

linden-scripting-language's Introduction

Linden Scripting Language (LSL) syntax grammar, syntax highlighting and snippet files.

Maintained Open issues Open pull requests

About

In this repository you can find the syntax grammar, syntax highlighting and snippet files for the Linden Scripting Language (LSL) of Second Life for different kinds of software.

Usage

Quick start

Bugs, issues & feature requests

Disclaimer

Second Life®, Linden Scripting Language and the inSL logo are trademarks of
Linden Research, Inc. The Builder's Brewery is neither affiliated with nor
sponsored by Linden Research.

inSL logo

linden-scripting-language's People

Contributors

buildersbrewery avatar mace68 avatar masterofsorts avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

linden-scripting-language's Issues

Linden Scripting Language doesn't seem to be working.

First, thank you for the effort put into all of these file for so many different editors. It must be a titanic effort!

Just wanted to note that the LSL support files for Visual Studio Code don't appear to be working. I've tried it with versions 0.7.0 and 0.8.0. I appreciate that this editor is a moving target that is actively under development. I'm confident that I've copied the vs.language.lsl folder into the correct lo the correct location for both versions.

Enhance SublimeText tooltips support

  • display flag info with default value for params
  • optimize TOOLTIP_DATA structure
  • when checking for description data, check for English description data (for now)
  • make tooltips smaller by not using headers anymore

Update keywords with changes from Oct-Dec 2016

16.10.07.320397

Constants

  • PRIM_ALLOW_UNSIT (int) 39
    • [ PRIM_ALLOW_UNSIT, integer flag ]
  • PRIM_SCRIPTED_SIT_ONLY (int) 40
    • [ PRIM_SCRIPTED_SIT_ONLY, integer flag ]
  • PRIM_SIT_TARGET (int) 41
    • [ PRIM_SIT_TARGET, integer active, vector offset, rotation rot ]

Functions

  • integer llSitOnLink(key agent_id, integer link)
Error return constant value description
SIT_NOT_EXPERIENCE -1 The script is not running as part of an experience with a valid experience key.
SIT_NO_EXPERIENCE_PERMISSION -2 The agent has not granted permission.
SIT_NO_SIT_TARGET -3 Unable to find an open sit target.
SIT_INVALID_AGENT -4 Unable to find specified agent.
SIT_INVALID_LINK -5 Unable to find specified link or the link constant would return multiple prims.
SIT_NO_ACCESS -6 The avatar does not have access to the parcel that the prim running this script is located in.
SIT_INVALID_OBJECT -7 This value is returned if the llSitOnLink is trying to force the user to sit on something that cannot be sat upon (such as an attachment).

16.11.02.321369

Constants:

  • OBJECT_GROUP_TAG (int) 33
  • OBJECT_TEMP_ATTACHED (int) 34

16.12.03.322072

Constants:

  • OBJECT_ATTACHED_SLOTS_AVAILABLE (int) 35

Autocompletion in Notepad++, hints/popup not always working

Issue Summary

use the Autocomplition feature (without FingerText enabled)

  • popup hint works on llListen but not on listen
  • works on llSensor but not on sensor

Steps to Reproduce

  1. type llListen
  2. go on and add (
  3. see the popup/hint explaining parameters

compared to

  1. type listen
  2. go on and add (
  3. see nothing happening

Technical details

bug is as follows:

    <KeyWord name="listen" func="yes">
        <Overload descr="Triggered by chat, use llListen to enable and filter.">
            <Param name="integer channel" />
            <Param name="string name" />
            <Param name="key id" />
            <Param name="string message" />
        </Overload>
    </KeyWord>

has no retVal="XXX". However for functions I could spot retVal="void", but even retVal="" makes it work again

    <KeyWord name="listen" func="yes">
        <Overload retVal="" descr="Triggered by chat, use llListen to enable and filter.">
            <Param name="integer channel" />
            <Param name="string name" />
            <Param name="key id" />
            <Param name="string message" />
        </Overload>
    </KeyWord>
  • Editor: Notepadd++
  • Version: 7.3.3
  • Operating System: Win7 x64

HTTP_ACCEPT

Flag (int value) Parameter Default Description
HTTP_ACCEPT 8 [ string MIME_type ] "text/plain;charset=utf-8" HTTP_ACCEPT parameters can be passed to limit the number of mime types that are sent in the Accept: header of the HTTP request. Specified mime types may include character set and q parameters. This parameter may be specified multiple times. The specified mime type must be one already recognized by llHTTPRequest. The Content-Type header in the response is checked against the specified HTTP_ACCEPT parameters. If the value of the header is not in the list of acceptable mime types, llHTTPRequest will return 415 as a result code and the body will be "Unsupported or unknown Content-Type."

from 17.06.13.327111

fix functions

  • make key k a string k
    • llReadKeyValue
    • llCreateKeyValue
    • llUpdateKeyValue
    • llDeleteKeyValue

Improve Notepad++ install manual

Issue Summary

Notepad++ makes use of two directory structures

  • C:\Program Files (x86)\Notepad++ (using 32bit version, 'install dir')
  • C:\Users\USERNAME\AppData\Roaming\Notepad++

some of the files should go to user account folders (funtionList.xml, userDefineLang.xml)
others need to be in install dir (lsl.xml)

Steps to Reproduce

  1. copy lsl.xml into user folder structure
  2. see that it does not work
  3. delete file from user folder structure, add into install dir folders
  4. see autocomplete working

compare to funtionList.xml
where the NP++ website says

It can be found in %APPDATA%\notepad++\ or in Notepad++ installed directory if you use zip package.

putting it into user account folder structure makes that feature work and is probably better than editing the functionList.xml that is already present in install dirs

userDefineLang.xml definitely should go into %APPDATA% structure

Technical details

  • Editor: NP++
  • Version: 7.3.3
  • Operating System: Win7 x64

Error on Vim

So I'm trying to run this on Vim and it works, but it would seem comments aren't being processed correctly?
I'm not familiar enough with Vim to make much more sense out of the error message.

Error detected while processing /home/martin/.vim/syntax/lsl.vim:
line 1246:
E866: (NFA regexp) Misplaced +
E64: \+ follows nothing
E475: Invalid argument: lslOperator display '\+\+|\-\-|<<|>>|&&?|\|\|?|\^|~|[!%<>=*\+\-\/]=?'
line 1261:
E866: (NFA regexp) Misplaced {
E64: \{ follows nothing
E475: Invalid argument: lslBlock display start='\{' end='\}' fold transparent contains=ALL
line 1264:
E54: Unmatched \(
E54: Unmatched \(
E475: Invalid argument: lslParen display start='\(' end='\)' fold transparent contains=ALL
line 1282:
E402: Garbage after pattern: start='\/\/' end='$' contains=lslCommentMulti,lslCommentTodo,@Spell
E475: Invalid argument: lslComment display start='\/\/' end='$' contains=lslCommentMulti,lslCommentTodo,@Spel
l
line 1285:
E402: Garbage after pattern: start='\/\*' end='\*\/' contains=lslComment,lslCommentTodo,@Spell
E475: Invalid argument: lslCommentMulti display start='\/\*' end='\*\/' contains=lslComment,lslCommentTodo,@S
pell

highlight.js

Hi. Could someone with the knowhow please submit this repository's highlight-js code to the main highlight.js repository? It would be great to see LSL added to the main project and available in the checkboxes on their download page here.

Note: I tried to build highlight.js by following their build guide but I ran into nodejs troubles after adding the lsl.js file in this repository. I can elaborate about my attempts if necessary but thought it may just be better if LSL was simply added to the main highlight.js repository.

Error in userDefinedLang.xml

Issue Summary

This causes an issue because ... It shows up in the xml file

Steps to Reproduce

  1. Open userDefineLang.xml
  2. Look at line 33.
  3. You'll see:
<Keywords name="Delimiters" id="24">00&quot; 01\ 02&quot; 03BUG: 03Bug: 03bug: 03FIXME: 03Fixme: 03fixme: 03TEST: 03Test: 03test: 03TODO: 03Todo: 03todo: 04 05((EOL)) 05((EOL)) 05((EOL)) 05((EOL)) 05((EOL)) 05((EOL)) 05((EOL)) 05((EOL)) 05((EOL)) 05((EOL)) 05((EOL)) 05((EOL)) 06 07 08 09 10 11 12 13 14 15 16 17 18 19 20 21 22 23</Keywords>

This indicates some sort of error with xml file. It's probably easily cleaned up by someone who knows what they are doing. I tried working with it in Notepad++ using the language editor, but I created more problems than solve this one. That may be because I'm not very familiar with how to work in Notepad++. Hopefully, someone with more experience will take this on and clean things up.

Technical details

  • Editor: Notepad++
  • Version:
  • Operating System: Windows

OBJECT_*

Flag (int value) Description Length, when typecast to a string Description
OBJECT_CREATION_TIME 36 Gets object's creation time. timestamp string timestamp
OBJECT_SELECT_COUNT 37 ... count integer count
OBJECT_SIT_COUNT 38 ... count integer count
OBJECT_SELECTED * Get, if object is selected. boolean integer boolean
OBJECT_SAT_UPON * Get, if object is sat upon. boolean integer boolean
OBJECT_REZ_TIME * Gets object's rez time. timestamp string timestamp
OBJECT_RETURN_TIME * Gets object's return time. timestamp string timestamp

from 17.08.11.328159

Add changes from Second Life server 16.10.07.320397

Add changes from Second Life server 16.10.07.320397

Constants

  • PRIM_ALLOW_UNSIT (int) 39
    • [ PRIM_ALLOW_UNSIT, integer flag ]
  • PRIM_SCRIPTED_SIT_ONLY (int) 40
    • [ PRIM_SCRIPTED_SIT_ONLY, integer flag ]
  • PRIM_SIT_TARGET (int) 41
    • [ PRIM_SIT_TARGET, integer active, vector offset, rotation rot ]

Functions

  • integer llSitOnLink(key agent_id, integer link)
Error return constant value description
SIT_NOT_EXPERIENCE -1 The script is not running as part of an experience with a valid experience key.
SIT_NO_EXPERIENCE_PERMISSION -2 The agent has not granted permission.
SIT_NO_SIT_TARGET -3 Unable to find an open sit target.
SIT_INVALID_AGENT -4 Unable to find specified agent.
SIT_INVALID_LINK -5 Unable to find specified link or the link constant would return multiple prims.
SIT_NO_ACCESS -6 The avatar does not have access to the parcel that the prim running this script is located in.
SIT_INVALID_OBJECT -7 This value is returned if the llSitOnLink is trying to force the user to sit on something that cannot be sat upon (such as an attachment).

HTTP_USER_AGENT

Flag (int value) Parameter Default Description
HTTP_USER_AGENT 7 [ string user_agent_value ] "" The user agent value is appended to the one generated by LSL itself. It should follow the syntax from the HTTP standard like: "My-Script-Name/1.0 (Mozilla compatible)".

to be used with llHTTPRequest

from 17.06.13.327111

Please update with recent changes to LSL?

Issue Summary

This causes an issue because I think this repo isn't maintained

Steps to Reproduce

look at code commit and issue dates

can the owner just lock the repo so we dont end up here full of hope, install shit and throw PC out of the window ?

Technical details

  • Editor: vscode
  • Version: idfk idfc
  • Operating System: winblows

Atom package name collision.

Issue Summary

(I could query quickly submit a pull request, but I feel this is a Bulder's Brewery administrative decision that should be made first.)

The package name for the Atom plugin is language-lsl which conflicts with digitalfiz's LSL plugin.

Package name collision prevents updates from within Atom.

I'd recommend changing the package name to something different, perhaps like language-lsl-bb to distinguish the Bulder's Brewery version from the digitalfiz version.

Steps to Reproduce

  1. Install the Bulder's Brewery LSL package.

You'll see the update message continually because it's trying to reconcile the installed Bulder's Brewery package with the registered language-lsl package by digitalfiz.

fd90c61fa51f21f0608df4c0bb0d2954

Also, the two plugins collide. If I install the digitalfiz LSL plugin, an then the Builder's Brewery plugin, the digitalfiz plugin thinks that there's an update for it (because of the naming collision).

If I install the Builder's Brewery plugin first, the digitalfiz LSL plugin won't install.

Reasoning

To address the rebuttal, "Why would anybody want to install both?"

  1. It would be nice to compare the two plugins.
  2. It would open the road to making the Builder Brewery's version available to everybody who searches for LSL in Atom's plugin manager. Right now only the digitalfiz version appears in the list.)
  3. To be blunt, I see that reasoning as excusing broken behavior to avoid fixing it.

ecf742cd72e1cebf05dde5b325252a84

Technical details

  • Editor: Atom
  • Version: 1.22.0 x64
  • Operating System: Window 10

Add new constants

integer OBJECT_PRIM_COUNT = 30;
integer OBJECT_TOTAL_INVENTORY_COUNT = 31;
integer OBJECT_REZZER_KEY = 32;

color-scheme issues in sublime text

The color-scheme included with the sublime text syntax makes it so unless you have a light theme it clashes really bad.

I would suggest removing it or adding a dark version for those with dark schemes.

with theme

without theme

[WIP] Fix issues with LSL syntax for Sublime Text 3

  • Add syntax_tests for LSL.
  • Redo *.sublime-syntax file.
    # http://www.sublimetext.com/docs/3/syntax.html
    
     - match: some-regex
       push: target-scope
       with_prototype:
         - match: some-regex # or include
           scope: target-scope
         - match: some-regex # look ahead
           pop: true
  • prevent user functions within other scopes
  • fix conditional blocks following keyword.control.conditional
  • scope punctuation.accessor and elements following:
    • vectors
    • rotations

Visual Studio Code extension doesn't work

The extension doesn't show up in VScode after placing the LSL folder in my extensions directory (which does contain all the other extensions I've installed)

I have the newest VScode version. It might be my fault, I'm a VScommunity 2015 user and this is my first time using VSCode. but all the other extensions I installed showed up, with similar file structure in those folders, but the LSL extension has no effect on VSCode when I open a .lsl file. and it doesn't show up in my extensions list in VSCode either.

Add changes from 16.05.24.315768

ATTACH_FACE_JAW, integer 47
ATTACH_FACE_LEAR, integer 48
ATTACH_FACE_LEYE, integer 50
ATTACH_FACE_REAR, integer 49
ATTACH_FACE_REYE, integer 51
ATTACH_FACE_TOUNGE, integer 52
ATTACH_GROIN, integer 53
ATTACH_HIND_LFOOT, integer 54
ATTACH_HIND_RFOOT, integer 55
ATTACH_LHAND_RING1, integer 41
ATTACH_LWING, integer 45
ATTACH_RHAND_RING1, integer 42
ATTACH_RWING, integer 46
ATTACH_TAIL_BASE, integer 43
ATTACH_TAIL_TIP, integer 44

add changes for EEP LSL

  • add new constants: SKY_ABSORPTION_CONFIG, SKY_AMBIENT, SKY_CLOUDS, SKY_DENSITY_PROFILE_COUNTS, SKY_DOME, SKY_GAMMA, SKY_GLOW, SKY_LIGHT, SKY_MIE_CONFIG, SKY_MOON, SKY_PLANET, SKY_RAYLEIGH_CONFIG, SKY_REFRACTION, SKY_STAR_BRIGHTNESS, SKY_SUN, SKY_TEXTURE_DEFAULTS, SKY_TRACKS, WATER_BLUR_MULTIPLIER, WATER_FOG, WATER_FRESNEL, WATER_NORMAL_SCALE, WATER_REFRACTION, WATER_TEXTURE_DEFAULTS, WATER_WAVE_DIRECTION
  • add new functions: llGetDayLength, llGetDayOffset, llGetEnvironment, llGetMoonDirection, llGetMoonRotation, llGetRegionDayLength, llGetRegionDayOffset, llGetRegionMoonDirection, llGetRegionMoonRotation, llGetRegionSunDirection, llGetRegionSunRotation, llGetSunRotation

See also:

[Suggestion] Include, or add a link to, the LSL syntax checker for the Nova editor (macOS)

Hi! This is neither a feature request, much less an issue, but I just wanted to tell you that you're most welcome to add to your list the LSL syntax extension that I've been writing for the Nova code editor. Nova users can simply add it from the Nova Extension Library, searching for 'LSL'.

Nova is a commercial product that only runs under macOS, so I expect its usage by SL scripters to be very small. Still, the extension is there for anyone who wants to use it; it's still not 100% functional — like everything else, it's a WiP — and I'm trying to get it up-to-date with the KWDB automatically (it's absurd not to use Sei Lisa and Mako Nozaki's fantastic work!), so it might make more sense to add it as a Git submodule on your repository — or perhaps just a link from the README could suffice.

Thanks!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.