Skip to content

V2 Lexicon

Math edited this page Dec 8, 2024 · 20 revisions

Objects

xmlscript(ScriptPath)

subpart(SubpartName)

button(SubpartName, DummyName)

emissive(EmissiveMaterialID)

emitter(DummyName)

light(DummyName, Radius, EnableFlare, falloff, intensity)

light(DummyName, Radius, EnableFlare, falloff)

light(DummyName, Radius, EnableFlare)

light(DummyName, Radius)

Actions

toolcore()

  • functional()
  • powered()
  • enabled()
  • activated()
  • leftclick()
  • rightclick()
  • click()
  • firing()
  • hit()
  • rayhit()

weaponcore()

  • reloading()
  • firing()
  • tracking()
  • overheated()
  • turnon()
  • turnoff()
  • burstreload()
  • nomagstoload()
  • prefire()
  • emptyongameload()
  • stopfiring()
  • stoptracking()
  • lockdelay()
  • init()
  • homing()
  • targetaligned()
  • whileon()
  • targetranged100()
  • targetranged75()
  • targetranged50()
  • targetranged25()

button(KEWRD)

  • pressed(KEWRD)
  • hovering(KEWRD)

block()

  • create()
  • built()
  • damaged()
  • working()
  • notworking()

inventory()

  • changed(KEWRD)

power()

  • consumed(KEWRD)
  • produced(KEWRD)

production()

  • startproducing()
  • stopproducing()

distance(FLOAT)

  • changed(KEWRD)
  • arrive()
  • leave()

shiptool()

  • activated(KEWRD)

door()

  • open()
  • close()

cockpit()

  • enter()
  • exit()

landinggear()

  • lock()
  • unlock()
  • readylock()

Libraries

math

  • .sin(Value)
  • .cos(Value)
  • .abs(Value)
  • .max(a, b)
  • .min(a, b)
  • .floor(Value)
  • .ceiling(Value)
  • .round(Value)
  • .random()
  • .randomrange(minVal, maxVal)
  • .createvector(x, y, z)
  • .and(a, b)
  • .or(a, b)
  • .xor(a, b)

api

  • .log(Value)
  • .startloop(FunctionName, LoopDelay, LoopCount, DelayTime)
  • .startloop(FunctionName, LoopDelay, LoopCount)
  • .stoploop(FunctionName)
  • .delayfunction(FunctionName, FunctionDelay)
  • .stopdelays()
  • .assert(a, b)
  • .getlargegridmaxspeed()
  • .getsmallgridmaxspeed()
  • .getinputposition()
  • .getinputrotation()
  • .iscontrollingentity()

block

  • .delay(Value)
  • .translate(PositionVector, Time, Lerp)
  • .scale(ScaleVector, Time, Lerp)
  • .rotate(AxisVector, Angle, Time, Lerp)
  • .rotatearound(AxisVector, PivotVector, Angle, Time, Lerp)
  • .spin(Vector, Speed, Time)
  • .vibrate(Scale, Time)
  • .setresetpos()
  • .resetpos()
  • .resetrot()
  • .reset()
  • .pilottranslate(PositionVector, Time, Lerp)
  • .pilotscale(ScaleVector, Time, Lerp)
  • .pilotrotate(AxisVector, Angle, Time, Lerp)
  • .pilotrotatearound(AxisVector, PivotVector, Angle, Time, Lerp)
  • .pilotspin(Vector, Speed, Time)
  • .pilotvibrate(Scale, Time)
  • .pilotmovetoorigin(Time, Lerp)
  • .pilotreset()
  • .pilotresetpos()
  • .pilotsetresetpos()
  • .currentthrustpercent()
  • .productionitemmodel()
  • .isoccupied()
  • .isworking()
  • .isfunctional()
  • .getgasfilledratio()
  • .isarmed()
  • .iscountingdown()
  • .detonationtime()
  • .canaccess()
  • .entityhashcode()
  • .poweron()
  • .poweroff()
  • .toggledoor()
  • .closedoor()
  • .opendoor()
  • .togglelock()
  • .lockoff()
  • .lockon()

grid

  • .isnpc()
  • .iscontrolled()
  • .getatmosphericdensity()
  • .getplanetaltitude()
  • .getplanetgroundaltitude()
  • .getplanetmaxaltitude()
  • .getspeed()
  • .getnaturalgravity()
  • .geth2fuel()
  • .geto2fuel()
  • .getfuel(fuelString)

weaponcore

  • .getactiveammo()
  • .getheatlevel()
  • .getshotsfired()
  • .isshooting()

xmlscript

  • .run(AnimationId)
  • .stop()
  • .reset()

subpart

  • .delay(Value)
  • .setvisible(bool)
  • .setmodel(modelFilePath)
  • .setemissive(materialName, r, g, b, a)
  • .translate(PositionVector, Time, Lerp)
  • .translaterelative(PositionVector, Time, Lerp)
  • .scale(ScaleVector, Time, Lerp)
  • .rotate(AxisVector, Angle, Time, Lerp)
  • .rotaterelative(AxisVector, Angle, Time, Lerp)
  • .rotatearound(AxisVector, PivotVector, Angle, Time, Lerp)
  • .spin(Vector, Speed, Time)
  • .vibrate(Scale, Time)
  • .movetoorigin(Time, Lerp)
  • .setresetpos()
  • .resetpos()
  • .resetrot()
  • .reset()

button

  • .delay(Value)
  • .enabled(bool)
  • .interactable(bool)
  • .setvisible(bool)
  • .setmodel(modelFilePath)
  • .setemissive(materialName, r, g, b, a)
  • .translate(PositionVector, Time, Lerp)
  • .translaterelative(PositionVector, Time, Lerp)
  • .scale(ScaleVector, Time, Lerp)
  • .rotate(AxisVector, Angle, Time, Lerp)
  • .rotatearound(AxisVector, PivotVector, Angle, Time, Lerp)
  • .spin(Vector, Speed, Time)
  • .vibrate(Scale, Time)
  • .movetoorigin(Time, Lerp)
  • .setresetpos()
  • .resetpos()
  • .resetrot()
  • .reset()

emitter

  • .delay(Value)
  • .playparticle(particleName, scale, life, vectorScale, r, g, b)
  • .playparticle(particleName, scale, life, vectorScale)
  • .playparticle(particleName, scale, life)
  • .stopparticle()
  • .playsound(soundID)
  • .stopsound()

emissive

  • .delay(Value)
  • .setcolor(r, g, b, brightness, setAllSubpartColors)
  • .setsubpartcolor(actualSubpartName, r, g, b, brightness)
  • .tocolor(r, g, b, brightness, setAllSubpartColors, time, lerp)
  • .subparttocolor(actualSubpartName, r, g, b, brightness, time, lerp)

light

  • .delay(Value)
  • .setcolor(r, g, b)
  • .togglelight()
  • .lightoff()
  • .lighton()