Jump to content

Recommended Posts

Hey.

 

I have just started modding, and it seems  have hit an impass.  My mod won't load for some reason.  I think I did everything right...

 

Would anyone care to have a look at it?

 

I'm attaching it to this post.  Don't copy it pls :)

 

Thanks in advance.  I really have on idea what I'm doing here :)

Dream_Bringer.zip

Would that make the game crash?

 

You need that line in your modinfo.lua

 

If you don't have it, the game will crash. If it is empty (as above), it will be fine. If you add the Klei download page link, it will open that page to anyone clicking on it.

You need that line in your modinfo.lua

 

If you don't have it, the game will crash. If it is empty (as above), it will be fine. If you add the Klei download page link, it will open that page to anyone clicking on it.

 

So... I fixed that.  And it's STILL crashing.  Any ideas?

You have a few more errors in your code:

 

These are also recomended in your modinfo:

api_version = 6dont_starve_compatible = truereign_of_giants_compatible = true

Must correct this in your dreamstaff prefab:

Asset("ANIM", "anim/swap_dreamstaff.zip")--MUST BE THISAsset("ANIM", "anim/swap_dreamstaff.zip"),--NOTICE THE ','

That being said It still crashes for me and there is nothing in the log. I would guess it is in your spriter files, Judging from your other mistakes it may just a typo. I can't debug the files because I just have the anim folder not the exported folder.

If you post the spriter files I will take a look at them.

You have a few more errors in your code:

 

These are also recomended in your modinfo:

api_version = 6dont_starve_compatible = truereign_of_giants_compatible = true

Must correct this in your dreamstaff prefab:

Asset("ANIM", "anim/swap_dreamstaff.zip")--MUST BE THISAsset("ANIM", "anim/swap_dreamstaff.zip"),--NOTICE THE ','

That being said It still crashes for me and there is nothing in the log. I would guess it is in your spriter files, Judging from your other mistakes it may just a typo. I can't debug the files because I just have the anim folder not the exported folder.

If you post the spriter files I will take a look at them.

 

Thank you VERY much!  I had no idea that "Exported" was a required file.  I actually am not sure how to make one.  Any tips?  I'll search around.  If I come up with one, you'll get it.

 

@gardian20,

In case you didn't already read this tutorial it is an excellent one to go through:

http://forums.kleientertainment.com/topic/29427-tutorial-creating-a-handslot-equippable-item-from-scratch/

 

Thanks for the tutorial.  I went through, and now my item doesn't show up in my hands.  I attached the new one.  Thanks!

I know, the item's tiny, I'll fix that as soon as I can get it in my hands :D

Dream_Bringer.zip

Nice work!

When I first started I did the same thing.

Your file structure is wrong (it isn't clear in the tutorial)

You need to have the images for the spriter files one folder deeper than the .scml file.

You should do this for every scml file in your mod.

EDIT: Don't forget to correct the path in your spirter files after you do this.

4SuX8co.png

 

Edited by boardman94

To anticipate your next question here is how to fix your item not being in your hand:

B8p0VeF.png

You need to edit the xml of your spriter file.

Open your .scml file with notepad.

 It should look like this:

<?xml version="1.0" encoding="UTF-8"?><spriter_data scml_version="1.0" generator="BrashMonkey Spriter" generator_version="b10">    <folder id="0" name="swap_dreamstaff">        <file id="0" name="swap_dreamstaff/swap_dreamstaff.png" width="96" height="166" pivot_x="0" pivot_y="1"/>    </folder>    <entity id="0" name="swap_dreamstaff">        <animation id="0" name="BUILD" length="1000">            <mainline>                <key id="0">                    <object_ref id="0" timeline="0" key="0" z_index="0"/>                </key>            </mainline>            <timeline id="0" name="swap_dreamstaff_000">                <key id="0" spin="0">                    <object folder="0" file="0" x="6.051546" y="25.245509" pivot_x="0.448454" pivot_y="0.254491"/>                </key>            </timeline>        </animation>    </entity></spriter_data>

You need to copy the pivot point you set up to the pivot point of the image:

<object folder="0" file="0" x="6.051546" y="25.245509" pivot_x="0.448454" pivot_y="0.254491"/>

Get the pivot_x and the pivot_y and copy them into this line:

<file id="0" name="swap_dreamstaff/swap_dreamstaff.png" width="96" height="166" pivot_x="0" pivot_y="1"/>

So line 4 will look like this: (The actual numbers will be different)

<file id="0" name="swap_dreamstaff/swap_dreamstaff.png" width="96" height="166" pivot_x="0.448454" pivot_y="0.254491"/>

You will need to repeat this every time you change the pivot point of the "swap" version of the item.

This happens because DS uses the pivot point of the image and spriter uses the pivot point of the animation object. So you have to manually copy them over.

To anticipate your next question here is how to fix your item not being in your hand:

B8p0VeF.png

You need to edit the xml of your spriter file.

Open your .scml file with notepad.

 It should look like this:

<?xml version="1.0" encoding="UTF-8"?><spriter_data scml_version="1.0" generator="BrashMonkey Spriter" generator_version="b10">    <folder id="0" name="swap_dreamstaff">        <file id="0" name="swap_dreamstaff/swap_dreamstaff.png" width="96" height="166" pivot_x="0" pivot_y="1"/>    </folder>    <entity id="0" name="swap_dreamstaff">        <animation id="0" name="BUILD" length="1000">            <mainline>                <key id="0">                    <object_ref id="0" timeline="0" key="0" z_index="0"/>                </key>            </mainline>            <timeline id="0" name="swap_dreamstaff_000">                <key id="0" spin="0">                    <object folder="0" file="0" x="6.051546" y="25.245509" pivot_x="0.448454" pivot_y="0.254491"/>                </key>            </timeline>        </animation>    </entity></spriter_data>

You need to copy the pivot point you set up to the pivot point of the image:

<object folder="0" file="0" x="6.051546" y="25.245509" pivot_x="0.448454" pivot_y="0.254491"/>

Get the pivot_x and the pivot_y and copy them into this line:

<file id="0" name="swap_dreamstaff/swap_dreamstaff.png" width="96" height="166" pivot_x="0" pivot_y="1"/>

So line 4 will look like this: (The actual numbers will be different)

<file id="0" name="swap_dreamstaff/swap_dreamstaff.png" width="96" height="166" pivot_x="0.448454" pivot_y="0.254491"/>

You will need to repeat this every time you change the pivot point of the "swap" version of the item.

This happens because DS uses the pivot point of the image and spriter uses the pivot point of the animation object. So you have to manually copy them over.

 

Geez man, you're a lifesaver!  Mind if I PM you any more questions I have for other mods instead of making a whole thread?

ok just some obvious stuff:

cNA0w0g.png

(.scml.scml?)

This needs to have that nested folder just like swap_dreamstaff.

c9gTz4e.png

even after I made those changes It is crashing.

Going to do some more work on it. I'll let you know.

EDIT: It runs great now. I just had to recreate the swap_dreamstaff.scml file

Edited by boardman94

ok just some obvious stuff:

cNA0w0g.png

(.scml.scml?)

This needs to have that nested folder just like swap_dreamstaff.

c9gTz4e.png

even after I made those changes It is crashing.

Going to do some more work on it. I'll let you know.

EDIT: It runs great now. I just had to recreate the swap_dreamstaff.scml file

Still doesn't work...

This is getting ridiculous.  Could you send me your copy that works so I could take a look at it?

 

Edited by gardian20

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
  • Create New...