Nebtown Wiki
Advertisement

Keyboard Presses[]

Function Returns Description
E:keyW() N Returns 1 if E is pressing W
E:keyA() N Returns 1 if E is pressing A
E:keyS() N Returns 1 if E is pressing S
E:keyD() N Returns 1 if E is pressing D
E:keySpace() N Returns 1 if E is pressing Space
E:keyR() N Returns 1 if E is pressing R
E:keyCtrl() N Returns 1 if E is pressing Control
E:keyMouse1() N Returns 1 if E is pressing Mouse1
E:keyMouse2() N Returns 1 if E is pressing Mouse2
E:keyAlt() N Returns 1 if E is pressing Alt
E:keyShift() N Returns 1 if E is pressing Shift
E:keyE() N Returns 1 if E is pressing E
E:keyG() N Returns 1 if E is pressing Zoom
E:keyAlt1() N Returns 1 if E is pressing Alt1
E:keyAlt2() N Returns 1 if E is pressing Alt2
E:keyLeft() N Returns 1 if E is pressing Left
E:keyRight() N Returns 1 if E is pressing Right
E:keyTab() N Returns 1 if E is pressing Tab
E:keyRun() N Returns 1 if E is pressing Run
E:keyCancel() N Returns 1 if E is pressing Cancel
E:keyBullrush() N Returns 1 if E is pressing Bullrush lolwut
E:keyWeapon1() N Returns 1 if E is pressing Weapon1
E:keyWeapon2() N Returns 1 if E is pressing Weapon2
E:heldWeapon() E Returns the weapon entity held by E

The constraints Section here was deleted for being a lame copycat of the one below.

Entity Adjustments[]

Function Returns Description
E:setScale(V) Sets the visual (NOT COLLISION) scale of E to V [(3,3,3) would make it 3x larger]
E:explode() ENT GO BOOM
E:setCollisionGroup(N) Set's the collision group of E to N.(Collision Groups)
E:print(S) N Prints S to the screen of E in chat format.
E:uniqueID() N Returns the unique ID of E.
E:setBloodColor(N)
E:hudBox(S,Nx,Ny,Nz,V1,V) Creates a small box filled with S on E's screen, at (Nx,Ny), with V1 background color, and V2 text color. I forget what Nz does.
E:hudText(S,Nx,Ny,V) Creates disembodied text on the screen of player E, with coordinates (Nx,Ny), and color V.

File Reading Functions[]

Function Returns Description
fileReadString(S) S Returns the string stored serverside at S
fileReadArray(S) R Returns the array stored serverside at S
fileReadTable(S) T Returns the table stored serverside at S
fileWriteString(S,S2) Writes the string S2 to a serverside file at S
fileWriteArray(S,R) Writes the array R to a serverside file at S
fileWriteTable(S,T) Writes the table T to a serverside file at S
fileList(S) R Returns an array of all filenames in directory S
fileDelete(S) Deletes the file stored serverside at S

Prop Core (heavily modified)[]

Function Returns Description
propSpawn(S,V,A) E Spawns and returns a prop_physics with S modle, at V and A. [V & A optional]
E:propDelete() Removes the prop (careful)
E:propFreeze(N) Freezes E, like the physgun
E:propNotSolid(N) See setNotSolid
E:reposition(V) S Teleports E to V
E:reposition2(V) S Teleports E to V *differently*
E:forceReposition(V) Ignores validity checking
E:forceReangle(A) Ignores validity checking
E:reangle(A) Teleports E so it is angled A
E:rerotate(A) Alias of reangle
E:parent() E Returns the parent of E
E:parentTo(E2) Parents E to E2
E:forceParentTo(E) Disregards validity checking
E:setOwnerless() Makes E ownerless, according to SimplePropProtection
hookUse(N) Makes the chip "Use"able. Only needs to be called once
inUseBy() E Returns the entity who is using the chip
inUse() N Returns 1 if the chip is being used
entitySpawn(S,S2,V) E Spawns an entity with class S, model <model, at V
entitySpawn(S,S2,V,A) E Spawns an entity with class S, model <model, at V and A
effectSpawn(S,V) E Spawns the effect S at location V probably.
effectSpawn(S,V,V2) E Spawns an effect S at location V, with the destination V2 probably.
effectSpawn(S,V,V2,E) E Spawns an effect S at location V, with the destination V2, attached to E probably.
effectSpawn(S,V,V2,E,N,N2,N3) E Spawns an effect S at location V, with the destination V2, attached to E, with N radius, N2 scale, and N3 magnitude, probably.

Constraints[]

Function Returns Description
E:getConstraints2() R Like getConstraints(), returns an array of all entities in E's constraint system, including E
E:getAllWelds() R A more expensive version of getConstraints(), attempts to find all entities that are connected via welds to E
E:constraintBreakAll() Breaks EVERY CONSTRAINT on E
axis(E,V,E2,V2) Creates an axis between E and E2 at vector positions local to each ent.
axis(E,V,E2,V2,N) Creates an axis between E and E2 at vector positions local to each ent, with N friction.
ballsocket(E,V,E2) Creates a ballsocket between E and E2 at V, which is local to E
winch(N,E,V,E2,V2,N2) Makes a winch constraint (stored at index N) between E and E2, at vectors local to their respective ents, with N2 width.
hydraulic(N,E,V,E2,V2,N2) Makes a hydraulic constraint (stored at index N) between E and E2, at vectors local to their respective ents, with N2 width.
E:setHydraulic(N,N2) Sets a hydraulic/winch stored at index N inside E (the first entity) to be N2 long.
E:noCollide(E2) Nocollides E to E2
E:noCollide(R) Nocollides E to every entity in R
R:noCollideTogether() Nocollides every entity in R to eachother (EXPENSIVE)
E:noCollideAll(N) Nocollides E to entities/players, just like Right Click of No-Collide Stool
rope(E,V,E2,V2) Creates a rope between E and E2 at vector positions local to each ent.
rope(E,V,E2,V2,N) Creates a rope between E and E2 at vector positions local to each ent, with N additional length.
rope(E,V,E2,V2,N,N2,S) Creates a rope between E and E2 at vector positions local to each ent, with N additional length, N2 width, and S material.
ropeLength(E,V,E2,V2,N) Creates a rope between E and E2 at vector positions local to each ent, specifically with length N
E:ropeBreakAll() Breaks all ropes on E
slider(E,V,E2,V2) Creates a slider between E and E2 at vector positions local to each ent.
slider(E,V,E2,V2,N) Creates a slider between E and E2 at vector positions local to each ent, with N width.
E:sliderBreakAll() Breaks all sliders on E
E:weld(E2) Welds E to E2
E:weld(R) Welds every entity in R to E
E:weldBreak(E2) Breaks the weld between E and E2
E:weldBreak(R) Breaks all welds between E and every entity in R
E:weldBreakAll() Breaks all welds on E
R:weldBreakAll() Breaks all welds on every entity in R
Advertisement