Garry's Mod

Garry's Mod

132 ratings
Contraption Framework
   
Award
Favorite
Favorited
Unfavorite
Content Type: Addon
Addon Type: Server content
Addon Tags: Build
File Size
Posted
Updated
30.122 KB
5 Feb, 2024 @ 4:46pm
12 Jul @ 11:27am
23 Change Notes ( view )

Subscribe to download
Contraption Framework

Description
Contraption Framework (CFW)


Monitors constraints to create "Contraption" objects and adds callbacks for changes made to contraptions for efficient contraption-aware functionality.

For example, in order to calculate the total mass of a contraption traditionally one would need to iterate over every entity on the contraption and store this information somewhere.

With Contraption Framework (CFW), a callback is run whenever an entity is added to or removed from a contraption and the total mass is added to or subtracted from the total stored in memory on the contraption object.



https://github.com/ACF-Team/CFW
46 Comments
win xp 28 Jun @ 1:14pm 
[Contraption Framework] lua/cfw/classes/link_sv.lua:72: attempt to call method 'Sub' (a nil value)
1. Sub - lua/cfw/classes/link_sv.lua:72
2. disconnect - lua/cfw/core/connectivity_sv.lua:76
3. fn - lua/cfw/core/parenting_sv.lua:117
4. unknown - lua/ulib/shared/hook.lua:109
cozmo 28 Apr @ 7:33am 
I have this downloaded but it says its not installed
thecraftianman 24 Apr @ 8:56pm 
Could you send a link to the dupe so that I can try taking a look at it?
vegan food user 24 Apr @ 5:21pm 
Yeah, I tried doing that already but that didn't help,
thecraftianman 24 Apr @ 4:51pm 
ULib isn't related to this at all, but there might be something else conflicting with this addon. Try disabling any addons that also do things to prop contraptions and see if that fixes it.
vegan food user 21 Apr @ 10:46pm 
I have 0 understanding in coding but is this due to possibly a mod I have called "uLib"?
and if so, is it THIS mod's problem in particular or uLib's?

also, dunno if this is relevant but my rt cameras like the ones from wiremod and/or the "advanced multiple rt cameras" addon are all somehow bugged. like the rt monitor shows the previous camera, if there is one, that isn't even connected to it anyhow. It happened after I downloaded this mod, which also so happened to be when garry's mod got updated and now I don't know who to blame.

(sorry for 2 comments, can't post comments with more than 1k characters)
vegan food user 21 Apr @ 10:46pm 
there are some interesting things happening to my gmod with this addon installed. so basically when I try to spawn a dupe of mine that has totally no relation (except maybe vanilla destructible props) to this addon, it creates an error:

[Contraption Framework] lua/cfw/core/connectivity_sv.lua:47: attempt to call method 'Merge' (a nil value)
1. connect - lua/cfw/core/connectivity_sv.lua:47
2. unknown - lua/cfw/core/constraints_sv.lua:40

Timer Failed! [Simple][@lua/cfw/core/constraints_sv.lua (line 28)]

continuing, I can't remove the dupe with the gmod undo feature. it just makes another error:

[Contraption Framework] lua/cfw/core/constraints_sv.lua:76: attempt to call method 'Remove' (a nil value)
1. fn - lua/cfw/core/constraints_sv.lua:76
2. Run - lua/ulib/shared/hook.lua:109
3. Do_Undo - lua/includes/modules/undo.lua:380
4. unknown - lua/includes/modules/undo.lua:463
5. unknown - lua/includes/modules/concommand.lua:54
thecraftianman 18 Mar @ 8:56pm 
Can you send them
SamThePlagueDoctor 18 Mar @ 7:47pm 
this shit causes so many fucking errors
barrientosdavian12 2 Feb @ 12:16am 
this is a thing i guess:
[Contraption Framework] entities/gmod_wire_expression2/core/custom/cfw.lua:29: attempt to call field 'newE2Table' (a nil value)
1. v - entities/gmod_wire_expression2/core/custom/cfw.lua:29
2. Run - lua/includes/modules/hook.lua:96
3. Init - lua/cfw/classes/contraption_sv.lua:35
4. createContraption - lua/cfw/classes/contraption_sv.lua:15
5. connect - lua/cfw/core/connectivity_sv.lua:57
6. SetParent - lua/cfw/core/parenting_sv.lua:68
7. unknown - lua/entities/ent_jack_gmod_ezsatchelcharge.lua:35