Garry's Mod

Garry's Mod

gTASM - gTerminal programming language
 This topic has been pinned, so it's probably important
Chupacabr  [developer] 8 Jan, 2022 @ 3:54am
Problems
Here you can write your problem that you encountered while working with gTASM
< >
Showing 1-15 of 40 comments
BuoYancY_dabl 10 Jan, 2022 @ 1:45am 
When too much digits after point was a problem? Trying cmp what outputet compare to 1
OUTPUT = 0.16666666666667
[93]ERROR: LM:there are a lot of digits after the decimal point!(>10) - stop script
BuoYancY_dabl 10 Jan, 2022 @ 1:51am 
And i dont know why and how, but somehow:
db arr
mov arr[1], 6 - 1 + 1
print arr[1]

OUTPUT is somehow 4??
But, if i do this
mov arr[1], 6 - 1
mov arr[1], arr[1] + 1

OUTPUT will be 6
UPD: i think i found possible problem here. Its maybe + operator calculates first before - . But they should equal no matter how to put them.
Last edited by BuoYancY_dabl; 10 Jan, 2022 @ 2:08am
BuoYancY_dabl 10 Jan, 2022 @ 1:54am 
And last error. Seems code editor aplies to use of hot keys (ctrl + q = closes editor) saving hotkey (ctrl + s should equal save but its not) throwing lua error of gmod. Here is a log:

[gTASM - gTerminal programming language] lua/gterminal/cl_luapad_editor.lua:810: attempt to call field 'SaveScript' (a nil value)
1. _OnKeyCodeTyped - lua/gterminal/cl_luapad_editor.lua:810
2. unknown - lua/gterminal/cl_luapad_editor.lua:48

Still i dont think the mod is whacky, its too cool use it anyways but all those problems sometimes rage me out cuz you dont even know what is the problem: in me or in programing language.
Last edited by BuoYancY_dabl; 10 Jan, 2022 @ 2:07am
Chupacabr  [developer] 10 Jan, 2022 @ 3:14am 
Originally posted by BuoYancY_dabl:
When too much digits after point was a problem? Trying cmp what outputet compare to 1
OUTPUT = 0.16666666666667
[93]ERROR: LM:there are a lot of digits after the decimal point!(>10) - stop script
I've put a fuse on about this for now, I'd rather just trim such numbers.
Chupacabr  [developer] 10 Jan, 2022 @ 3:15am 
Originally posted by BuoYancY_dabl:
And i dont know why and how, but somehow:
db arr
mov arr[1], 6 - 1 + 1
print arr[1]

OUTPUT is somehow 4??
But, if i do this
mov arr[1], 6 - 1
mov arr[1], arr[1] + 1

OUTPUT will be 6
UPD: i think i found possible problem here. Its maybe + operator calculates first before - . But they should equal no matter how to put them.
sorry, dumb math module
Chupacabr  [developer] 10 Jan, 2022 @ 3:16am 
Originally posted by BuoYancY_dabl:
And last error. Seems code editor aplies to use of hot keys (ctrl + q = closes editor) saving hotkey (ctrl + s should equal save but its not) throwing lua error of gmod. Here is a log:

[gTASM - gTerminal programming language] lua/gterminal/cl_luapad_editor.lua:810: attempt to call field 'SaveScript' (a nil value)
1. _OnKeyCodeTyped - lua/gterminal/cl_luapad_editor.lua:810
2. unknown - lua/gterminal/cl_luapad_editor.lua:48

Still i dont think the mod is whacky, its too cool use it anyways but all those problems sometimes rage me out cuz you dont even know what is the problem: in me or in programing language.
next update
BuoYancY_dabl 10 Jan, 2022 @ 3:54am 
I dont test it a bit more, but
fill "#", 2, 1 throws an lua error due to "#" character. Is it same for every special characters?
Chupacabr  [developer] 10 Jan, 2022 @ 4:08am 
Originally posted by BuoYancY_dabl:
I dont test it a bit more, but
fill "#", 2, 1 throws an lua error due to "#" character. Is it same for every special characters?
# - symbol for comments I'll make an escape character for it
Last edited by Chupacabr; 10 Jan, 2022 @ 4:16am
BuoYancY_dabl 10 Jan, 2022 @ 11:13am 
db temp,1,2
db arr,3,4
mov arr[temp[1]], 5

throws an LM error. Problem in verifying only temp table with no argument inside arr table.
Chupacabr  [developer] 10 Jan, 2022 @ 11:15am 
Originally posted by BuoYancY_dabl:
db temp,1,2
db arr,3,4
mov arr[temp[1]], 5

throws an LM error. Problem in verifying only temp table with no argument inside arr table.
for such situations, use

mov arr[temp;1]5
Last edited by Chupacabr; 10 Jan, 2022 @ 11:16am
leopoldslikk795 22 Jan, 2022 @ 10:21am 
how to insert a disk in gterminal?
BuoYancY_dabl 22 Jan, 2022 @ 12:15pm 
Originally posted by leopoldslikk795:
how to insert a disk in gterminal?
Put disk near gTerminal and type command :disk id.
BuoYancY_dabl 1 Feb, 2022 @ 7:46am 
В описании пользования командой dbrem сказано, что она вставляет значение вместо того, чтобы убирать его, а так же показательные аргументы не правильны
Rockit208 7 Feb, 2022 @ 3:33pm 
Using the command "setpass" will not function normally, the terminal will think you are using the command "set" for the wire i/o device instead.
BuoYancY_dabl 10 Feb, 2022 @ 3:54am 
Originally posted by Rocco:
Using the command "setpass" will not function normally, the terminal will think you are using the command "set" for the wire i/o device instead.
Why not? As we know pl is sensitive to register, it can define db and dbrem.
< >
Showing 1-15 of 40 comments
Per page: 1530 50