Aller au contenu

Photo

Using the DA Toolset to compile scripts for use with Dragon Age 2


  • Veuillez vous connecter pour répondre
18 réponses à ce sujet

#1
Thought Process

Thought Process
  • Members
  • 191 messages
There are differences in DAE's script.ldf compared to DAO, so you'll want to use this helpful da2scripts.erf (drop it in your DAO packages\\core\\patch or perhaps packages\\core\\patch_tools? or anywhere applicable that will get the toolset to load it), which will replace DAO's script.ldf/cscript.ldf with the ones from DAE. Naturally this will break some stuff for building DAO content, so remove it when working with DAO content.

Notable changes:

GetLocalString (often used to obtain RUNSCRIPT_VAR) now takes an int for its variable name; this maps into the var_*.gda files, RUNSCRIPT_VAR is variable number 7, so instead of GetLocalString(GetModule(), "RUNSCRIPT_VAR") you'll want to use GetLocalString(GetModule(), 7)

You will need to pack any scripts you wish to use with the console runscript command into an ERF, the game will not load scripts from override on their own due to the override bug.

Modifié par Thought Process, 21 mars 2011 - 02:09 .


#2
blackmuffen

blackmuffen
  • Members
  • 10 messages
thnx

#3
elys

elys
  • Members
  • 458 messages
Is it the same with Set/GetLocalInt, because I could not get it working in script under DA2 (not using your LDF solution when I tried)

I had also problem with GetPartyPlotFlag related functions not working. Is it fixed with your solution ? :)

Modifié par elys, 21 mars 2011 - 02:11 .


#4
mesmerizedish

mesmerizedish
  • Members
  • 7 776 messages
So, what sort of amazingly awesome things does this gem make possible?

#5
Thought Process

Thought Process
  • Members
  • 191 messages
Yes, it's the same for any GetLocal/SetLocal*. There are no differences between DAO and DAE's GetPartyPlotFlag that I can see.

ishmaeltheforsaken wrote...

So, what sort of amazingly awesome things does this gem make possible?

I got tired of patching bytecode to make Vaddi/Vaddin function (working on some new changes), I found that DA Toolset has no issues with loading DAE's script.ldf/cscript.ldf and compiling code with them.

Modifié par Thought Process, 21 mars 2011 - 02:17 .


#6
elys

elys
  • Members
  • 458 messages
Hmm maybe I missed something when I tried.

Anyway thanks, that's great, so I don't need to use anymore workaround for local variable  not working :o
 

Modifié par elys, 21 mars 2011 - 02:22 .


#7
daywalker03

daywalker03
  • Members
  • 357 messages
I assume this will work for other scripts as well, as I would like to be sure that any scripts that I want to write specifically for DA2 work as intended in the game.

#8
Thought Process

Thought Process
  • Members
  • 191 messages
By other scripts, what do you mean?

#9
daywalker03

daywalker03
  • Members
  • 357 messages
New spells and talents mostly.

#10
Thought Process

Thought Process
  • Members
  • 191 messages
I'm not sure how they'd be any different from any other script, the only distinction of differing script types I know if is ncc vs ncs (client scripts vs server scripts)?

#11
elys

elys
  • Members
  • 458 messages
Using your ERF, i got a weird behaviour in the toolset:

int iVar = GetLocalInt(oModule, 1) report a mismatch type error when compiling

while this below works fine.

int iVar;
iVar = GetLocalInt(oModule, 1)

and then funnily below works too when compiling

String iVar = GetLocalInt(oModule,1)

#12
Thought Process

Thought Process
  • Members
  • 191 messages
Strange, I don't have that problem. Try renaming it to patch999.erf and dropping it into the patch directory.

#13
elys

elys
  • Members
  • 458 messages
Thanks I did, and the problem is gone. (I don't know if it was related to the file, or if the toolset somehow just got randomly crazy. But as long as it works I don't care )

#14
Thought Process

Thought Process
  • Members
  • 191 messages
I'm guessing the toolset somehow read two different copies of the script.ldf (the patches for DAO have updated script.ldf).

#15
Xodarap777

Xodarap777
  • Members
  • 42 messages
Thought Process: I sent you a PM. I'm very interested in modding for DA2, but I didn't mod for DAO, so I just need a little help getting started, if you have a minute :)

#16
Malcroix

Malcroix
  • Members
  • 360 messages
Compiling scripts with the toolset is great news, but in order to edit the existing scripts, how do you unpack the *.dat files which are in scripts.erf?

Modifié par Malcroix, 01 avril 2011 - 06:27 .


#17
ZabiGG

ZabiGG
  • Members
  • 45 messages
Hi and sorry to hijack your post... I'd love to see a port of the script found here: http://www.damods.co....php?topic=91.0, for DA2, but my coding skills are really lacking. Tried compiling the script using your patch in the toolset, and of course the constants are all wrong. Where can I find more info to make this work -- I love banter, what can I say?

Thanks in advance!

#18
pima52

pima52
  • Members
  • 3 messages
The toolset is a bomb. I tried to download it from different sources including Bioware and finally succeeded. I was able to get it on my PC, but it will not install, saddly after many tries and downloads of Python and other stuff that is required supposedly I just gave up and got rid of it. Perhaps some other game will come along where people can use something that is simple to install and use.Image IPB

#19
Wrathion

Wrathion
  • Members
  • 556 messages
Er...maybe this is something you put in the Toolset's own forum.

Modifié par Alexandrine Delassixe, 04 décembre 2012 - 09:16 .