Offset doesn't seem to accept functions

Forum rules
Please don't bump threads here if you have a problem - it will often be forgotten about if you do. Instead, make a new thread here.

Post a reply

Smilies
:D :) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :wink: :geek: :ugeek: :!: :?: :idea: :arrow: :| :mrgreen: :3: :wub: >:( :blergh:
View more smilies

BBCode is OFF
Smilies are ON

Topic review
   

Expand view Topic review: Offset doesn't seem to accept functions

Re: Offset doesn't seem to accept functions

by DoomRater » Thu Oct 19, 2017 1:31 pm

What about the crash afterwards though? I got an error from the console, but then it crashed with an Access Violation.

Re: Offset doesn't seem to accept functions

by Mikk- » Thu Oct 19, 2017 1:26 pm

[wiki]A_WeaponOffset[/wiki]

Re: Offset doesn't seem to accept functions

by Graf Zahl » Thu Oct 19, 2017 1:25 pm

The offsets are constants, this is entirely expected.

Offset doesn't seem to accept functions

by DoomRater » Thu Oct 19, 2017 1:08 pm

Produced in QZDoom version q2.0.0 (0473991c23da087669f9fcc591fd4fbdd89b1f3b).

I was looking to use Random() in an Offset parameter to make a weapon appear jittery when fired, but not always have the same pattern, but I received an error when trying just that saying it's a bad constant. Then it crashed.

Code: Select all

Script error, "9mm infinite.zip:ld_9mm.wad:DECORATE" line 51:
SC_GetNumber: Bad numeric constant "random".

Code: Select all

	  GLCK DDD 1 Offset(random(0,3), random(32,36))
And because a file is requested: https://www.dropbox.com/s/6c6m33p6lo8bw ... t.zip?dl=0

Top