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

Mapping and figuring out Sketch Nodes #258

Open
44 tasks done
monkeyman192 opened this issue Jul 24, 2020 · 0 comments
Open
44 tasks done

Mapping and figuring out Sketch Nodes #258

monkeyman192 opened this issue Jul 24, 2020 · 0 comments

Comments

@monkeyman192
Copy link
Owner

monkeyman192 commented Jul 24, 2020

As of Desolation (2.6), HG has added in something called Sketch Nodes which appear to be some kind of shader node handling in the entity files. They may also be to do with abandoned freighter scripting. (Just spitballing ideas really...)
These present a new challenge for a number of reasons:

  1. These "structs" do not seem to be mapped out in the same way as other ones are in the exe. They have some kind of mapping info, but I need to look into it more...
  2. Which struct is used to represent the data is dependent on the value of a string earlier on in the TkSketchNodeData struct
    (To be more precise, the byte data in the CustomData property of this struct is deserialised based on what the value of TypeName is)

Because of this, this data cannot be properly decompiled and recompiled (well, at least in a nice way we can modify) until the following structs have been mapped out.

  • SnOnSpawned
  • SnOnVariableChanged
  • SnOnBroadcastReceived
  • SnOnComponentEvent
  • SnIfValueIs
  • SnValueAsBool
  • SnFixedValue
  • SnGetVariableValue
  • SnSetVariableValue
  • SnSurveyVariableValue
  • SnSequence2
  • SnSequence3
  • SnWaitSeconds
  • SnWaitFrames
  • SnRandomNumber
  • SnBroadcastValueModel
  • SnBroadcastValueDistance
  • SnRaiseEvent
  • SnOnNodeActivated
  • SnOnTriggerVolume
  • SnOnAnimFrame
  • SnSetNodeActive
  • SnDeleteModel
  • SnPlayAnim
  • SnIfAnimIsPlaying
  • SnStopAnim
  • SnPlaySound
  • SnFadeModel
  • SnTranslateNode
  • SnRotateNode
  • SnSetLightIntensity
  • SnOnPlayerNear
  • SnSpawnParticles
  • SnStopParticles
  • SnDestroyDestructables
  • SnSetScannableComponentUsed
  • SnSetHazard
  • SnDamagePlayer
  • SnCameraShake
  • SnStopCameraShake
  • SnFadeMaterials
  • SnSetShaderValue
  • SnGiveReward
  • SnAddShootableHealth

I have prepended the prefix Sn as a shorthand for Sketch Node (similarly to how Gc is Game Component and Tk is Tool Kit (we think), so that they can be separated from the other structs.
Whilst they do not have this Sn in the exe, and instead.. well they technically don't have any prefix, but I thought it better to give them one here to give them the pretence of being a proper struct)

Also, I am not 100% sure that the list above is comprehensive, extracted it from the exe so hopefully it is!

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

No branches or pull requests

1 participant