Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Script errors when attempting to load dupe #305

Closed
dehelleman opened this issue Sep 17, 2020 · 6 comments
Closed

Script errors when attempting to load dupe #305

dehelleman opened this issue Sep 17, 2020 · 6 comments

Comments

@dehelleman
Copy link

dehelleman commented Sep 17, 2020

yesterday on 16 september 2020, i was working on an ACF & Sprops vehicle and saved it with no errors or issues along the way, when i attempted to load it again today on the 17th, it spat a multitude of script errors at me when attempting to load any of the versions i have saved on the 16th, while any other dupe i have works fine, including older dupes of the same vehicle, my Advdupe2-master is up to date and i have attempted loading it in other servers and singleplayer with no success.

the following error is what i get when i attempt to load the newest dupe of the vehicle:

[advdupe2] addons/advdupe2/lua/advdupe2/cl_ghost.lua:71: attempt to index local 'v' (a number value)

  1. LoadGhosts - addons/advdupe2/lua/advdupe2/cl_ghost.lua:71
  2. UploadFile - addons/advdupe2/lua/advdupe2/cl_file.lua:100
    3. DoNodeLeftClick - addons/advdupe2/lua/advdupe2/file_browser.lua:171
    4. unknown - addons/advdupe2/lua/advdupe2/file_browser.lua:978

the following error is what i get when i attempt to load the previous dupes of that vehicle made on the same day:

Missing HeadEnt index from Entities table[AdvDupe2Notify] File could not be decoded. (Missing HeadEnt index from Entities table) Upload Canceled.

m28t120a2 colossus newest.txt
m28t120a2 colossus previous.txt

@thegrb93
Copy link
Contributor

Duplicate of #280

We determined corruption to be the cause. If you can narrow down what entity is causing it, that'd be helpful. I'll look once I finish #187 and #306

@dehelleman
Copy link
Author

Duplicate of #280

We determined corruption to be the cause. If you can narrow down what entity is causing it, that'd be helpful. I'll look once I finish #187 and #306

i have discovered an E2 to be the issue, after contacting the friend who created this E2 about it, he believes the E2's @model does not function as it should after duplicating the vehicle a certain amount of times

@thegrb93
Copy link
Contributor

thegrb93 commented Oct 16, 2020

Does using the E2 without @model fix it? If so, what was @model being set to? @dehelleman

@thegrb93
Copy link
Contributor

thegrb93 commented Dec 2, 2020

My theory is table.Copy copied a metatable into the save table and it fucked with the serializer. Starting to grind down the advdupe2 issues though so will get to it soon.

@TheVayt
Copy link

TheVayt commented Dec 10, 2020

I had somewhat the same problem and found out which e2 caused this. I deleted pretty much all the code that doesn't affect the error and ended up with this:

@outputs Points:array Lines:table

for (I = 1, 7) { Points[I, vector] = vec(I) }
    
Lines:pushArray(array(Points[1,vector], Points[2,vector]))
Lines:pushArray(array(Points[4,vector], Points[3,vector]))
Lines:pushArray(array(Points[4,vector], Points[5,vector]))
Lines:pushArray(array(Points[5,vector], Points[6,vector]))
Lines:pushArray(array(Points[3,vector], Points[6,vector]))
Lines:pushArray(array(Points[4,vector], Points[7,vector]))

Points:clear()
#printTable(Lines)
#Lines:clear()

If you try to save this E2 with AD2 you instantly get [AdvDupe2Notify] DEBUG CHECK: Missing PhysicsObject table from HeadEnt Entity table and then you can't paste it.
If you clear Lines table in the end OR remove it from outputs OR push tables into Lines instead of arrays the error won't appear.

I also messed up with removing some lines in code above and somehow managed to save and then paste the E2, but then I got:
sv: Expression 2 (Fail Test 2): entities/gmod_wire_expression2/core/table.lua:146: invalid value (table) at index 1 in table for 'concat'

@thegrb93
Copy link
Contributor

I had somewhat the same problem and found out which e2 caused this. I deleted pretty much all the code that doesn't affect the error and ended up with this:

@outputs Points:array Lines:table

for (I = 1, 7) { Points[I, vector] = vec(I) }
    
Lines:pushArray(array(Points[1,vector], Points[2,vector]))
Lines:pushArray(array(Points[4,vector], Points[3,vector]))
Lines:pushArray(array(Points[4,vector], Points[5,vector]))
Lines:pushArray(array(Points[5,vector], Points[6,vector]))
Lines:pushArray(array(Points[3,vector], Points[6,vector]))
Lines:pushArray(array(Points[4,vector], Points[7,vector]))

Points:clear()
#printTable(Lines)
#Lines:clear()

If you try to save this E2 with AD2 you instantly get [AdvDupe2Notify] DEBUG CHECK: Missing PhysicsObject table from HeadEnt Entity table and then you can't paste it.
If you clear Lines table in the end OR remove it from outputs OR push tables into Lines instead of arrays the error won't appear.

I also messed up with removing some lines in code above and somehow managed to save and then paste the E2, but then I got:
sv: Expression 2 (Fail Test 2): entities/gmod_wire_expression2/core/table.lua:146: invalid value (table) at index 1 in table for 'concat'

Thanks. I'll test it sometime tonight.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants