Having trouble with making my own little mod.

Having trouble with making my own little mod.

Discuss game development here, from a distinct game project to an accessible third-party mutator, down to the interaction and design of individual units if you like.

Moderator: Moderators

SonOfWolf
Posts: 10
Joined: 25 Jan 2011, 11:53

Having trouble with making my own little mod.

Post by SonOfWolf »

Hey guys. I am having a little trouble.

I am following this tutorial

Code: Select all

http://springrts.com/wiki/The_Complete_Guide_To_Making_A_Spring_Game
I have made my little tank etc and the game sees it.

I used the mod provided called "Empty Game plus Tank" and I just replaced the tank3.3d0 and the texture for it in the mod.

When I try starting the game it loads up and then when the countdown to begin reaches zero the game crashes with error message written to "infolog.txt"

I was wondering if you guys could help me get my mod to work as I really want to get into modding.
BaNa
Posts: 1562
Joined: 09 Sep 2007, 21:05

Re: Having trouble with making my own little mod.

Post by BaNa »

post the infolog here (use pastebin), that should help with troubleshooting.
SonOfWolf
Posts: 10
Joined: 25 Jan 2011, 11:53

Re: Having trouble with making my own little mod.

Post by SonOfWolf »

BaNa wrote:post the infolog here (use pastebin), that should help with troubleshooting.

This is my infolog.txt paste

Code: Select all

http://pastebin.com/WaDrW3Mb
User avatar
Beherith
Posts: 5145
Joined: 26 Oct 2007, 16:21

Re: Having trouble with making my own little mod.

Post by Beherith »

Did you assign both a texture 1 and texture 2 to it in upspring? Are both of those textures in the folder unittextures?
SonOfWolf
Posts: 10
Joined: 25 Jan 2011, 11:53

Re: Having trouble with making my own little mod.

Post by SonOfWolf »

Beherith wrote:Did you assign both a texture 1 and texture 2 to it in upspring? Are both of those textures in the folder unittextures?
no, I only had one texture in on my unit. If I use my unit and text in the empty mod, it appears in game and is textured.


It can move about but cannot shoot.
SeanHeron
Engines Of War Developer
Posts: 614
Joined: 09 Jun 2005, 23:39

Re: Having trouble with making my own little mod.

Post by SeanHeron »

May be a simple typo on your side, but you write you replaced "tank3.3d0" , but in the infolog it says it couldn't find tank3.s3o .
So if that wasn't a typo, maybe you made a mistake renaming your file ? (Or of course you actually have it saved in 3do format, in which case I'd guess you'd have to change the unitdef [units/tank.lua] to point to a .3do file rather than the s3o).
User avatar
PTSnoop
Posts: 97
Joined: 09 Sep 2009, 19:05

Re: Having trouble with making my own little mod.

Post by PTSnoop »

I used the mod provided called "Empty Game plus Tank" and I just replaced the tank3.3d0 and the texture for it in the mod.
Hang on. Do you mean you replaced the original tank3.s3o with a new model called tank3.3d0 ?

The Spring engine supports 3do and s3o model formats, which are different to each other. The basic difference, as far as I can tell, is that 3do was used by OTA and handles textures differently.

If you're following the tutorial, then you should end up with a .s3o model, not a .3do. The solution should probably be to open up the model in UpSpring again and save as a .s3o .

If you're following other older tutorials as well, and really do have a properly textured .3do, then you'll just need to open up units/tank.lua and change 'ObjectName = "tank3.s3o" ' to 'ObjectName = "tank3.3do" '.

Hope this helps.
SonOfWolf
Posts: 10
Joined: 25 Jan 2011, 11:53

Re: Having trouble with making my own little mod.

Post by SonOfWolf »

PTSnoop wrote:
I used the mod provided called "Empty Game plus Tank" and I just replaced the tank3.3d0 and the texture for it in the mod.
Hang on. Do you mean you replaced the original tank3.s3o with a new model called tank3.3d0 ?

The Spring engine supports 3do and s3o model formats, which are different to each other. The basic difference, as far as I can tell, is that 3do was used by OTA and handles textures differently.

If you're following the tutorial, then you should end up with a .s3o model, not a .3do. The solution should probably be to open up the model in UpSpring again and save as a .s3o .

If you're following other older tutorials as well, and really do have a properly textured .3do, then you'll just need to open up units/tank.lua and change 'ObjectName = "tank3.s3o" ' to 'ObjectName = "tank3.3do" '.

Hope this helps.

Okay that completly confused me sorry.

Code: Select all

http://rapidshare.com/files/444511767/tankmod.sdz
this is my mod how I have it at the moment
User avatar
PTSnoop
Posts: 97
Joined: 09 Sep 2009, 19:05

Re: Having trouble with making my own little mod.

Post by PTSnoop »

I think I've found the problem. Ignore everything I said before; I was misinterpreting what you were saying.

The problem was, on the model in Upspring, you've labelled some of your pieces "Body", "Turret" and "Gun", but the script was looking for "body", "turret" and "gun". These labels are case sensitive.

All you have to do is open the model in Upspring and rename "Body", "Turret", and "Gun" to all lower case.
SonOfWolf
Posts: 10
Joined: 25 Jan 2011, 11:53

Re: Having trouble with making my own little mod.

Post by SonOfWolf »

PTSnoop wrote:I think I've found the problem. Ignore everything I said before; I was misinterpreting what you were saying.

The problem was, on the model in Upspring, you've labelled some of your pieces "Body", "Turret" and "Gun", but the script was looking for "body", "turret" and "gun". These labels are case sensitive.

All you have to do is open the model in Upspring and rename "Body", "Turret", and "Gun" to all lower case.
Still crashes, same error message.
SonOfWolf
Posts: 10
Joined: 25 Jan 2011, 11:53

Re: Having trouble with making my own little mod.

Post by SonOfWolf »

Okay sucess! After a fashion anyway.

I now have the basic mod. You start with a base. The base makes my tank and a builder and the builder can make a base, and an energy generating thingy. lol


The problem now is my tank cant attack. The button is there but it does nothing..

Sorry for being a noob guys!..

Code: Select all

http://rapidshare.com/files/444551054/MyMod.sdz
User avatar
MidKnight
Posts: 2652
Joined: 10 Sep 2008, 03:11

Re: Having trouble with making my own little mod.

Post by MidKnight »

Congratulations!
Thank you for being patient and articulate when asking for help! :mrgreen:
SonOfWolf
Posts: 10
Joined: 25 Jan 2011, 11:53

Re: Having trouble with making my own little mod.

Post by SonOfWolf »

MidKnight wrote:Congratulations!
Thank you for being patient and articulate when asking for help! :mrgreen:
Could someone take a look and help getting it to shoot? :)
User avatar
PTSnoop
Posts: 97
Joined: 09 Sep 2009, 19:05

Re: Having trouble with making my own little mod.

Post by PTSnoop »

I get the error message:
[f=0000088] LuaRules::RunCallIn: error = 2, UnitCreated, [string "scripts/tankscript.lua"]:1: piece not found: base
And looking at the new tank3.s3o in UpSpring again, there's no piece "base", but there's a piece "Tank.3ds"; if you rename that to "base", it should work. Or you could just delete the line 'local base = piece "base" ' from the top of scripts/tankscript.lua, since it doesn't actually do anything.

Having said that, your model apparently still has the pieces "Body", "Turret" and "Gun" with capital letters, so I could be looking at an older model version. Either way, they need to be all small letters.

With luck, unlike my earlier comments, this'll actually fix something...
SonOfWolf
Posts: 10
Joined: 25 Jan 2011, 11:53

Re: Having trouble with making my own little mod.

Post by SonOfWolf »

PTSnoop wrote:I get the error message:
[f=0000088] LuaRules::RunCallIn: error = 2, UnitCreated, [string "scripts/tankscript.lua"]:1: piece not found: base
And looking at the new tank3.s3o in UpSpring again, there's no piece "base", but there's a piece "Tank.3ds"; if you rename that to "base", it should work. Or you could just delete the line 'local base = piece "base" ' from the top of scripts/tankscript.lua, since it doesn't actually do anything.

Having said that, your model apparently still has the pieces "Body", "Turret" and "Gun" with capital letters, so I could be looking at an older model version. Either way, they need to be all small letters.

With luck, unlike my earlier comments, this'll actually fix something...
Wow. Thanks so much! :)

My unit is working. Turret turns and it shoots :)

Sorry If I seem over enthusiastic but I have tried many times before to mod this game and I always give up!

So now it works completely. I can try making my own base etc.

Expect to hear from me more in the future :)
User avatar
PTSnoop
Posts: 97
Joined: 09 Sep 2009, 19:05

Re: Having trouble with making my own little mod.

Post by PTSnoop »

Congratulations!
SonOfWolf
Posts: 10
Joined: 25 Jan 2011, 11:53

Re: Having trouble with making my own little mod.

Post by SonOfWolf »

PTSnoop wrote:Congratulations!
Okay im back haha, How do I make the base show the wireframe of my unit when it is building it?
User avatar
FLOZi
MC: Legacy & Spring 1944 Developer
Posts: 6242
Joined: 29 Apr 2005, 01:14

Re: Having trouble with making my own little mod.

Post by FLOZi »

I'll take a look when I get home.

edit: Nevermind, see you got all your stuff fixed, congrats. :-)
Last edited by FLOZi on 26 Jan 2011, 16:30, edited 1 time in total.
User avatar
knorke
Posts: 7971
Joined: 22 Feb 2006, 01:02

Re: Having trouble with making my own little mod.

Post by knorke »

hey welcome
pro tip: if you dont put links in

Code: Select all

 tags there are clickable ;)

[quote]How do I make the base show the wireframe of my unit when it is building it?[/quote]the wireframe of the builder unit is visible when it is being built. So the factory works.
I think the tank is missing the wireframe because of the errors in its script (piece "base", others explained)
Seems like units with scripterrors show no wireframe.

also please rename your mod to something that makes sense like Wolfmod.sdz or w/e instead of MyMod.sdz and also in modinfo.txt fill out all the keys. Of course does not really matter when the mod is on your HDD but when you show it to others (even if just for error searching) it makes things much easier. Like appereantly there already was a "example mod" in my folder, confused me a bit  :roll:

instead of changing piece names in upspring, you can also change piece names in the script which is usually faster than opening the model, saving etc.

hope you know about these commands, it makes modding much easier:
http://answers.springlobby.info/questions/393/how-can-i-easily-test-my-mod
SonOfWolf
Posts: 10
Joined: 25 Jan 2011, 11:53

Re: Having trouble with making my own little mod.

Post by SonOfWolf »

knorke wrote:hey welcome
pro tip: if you dont put links in

Code: Select all

 tags there are clickable ;)
[/quote]


Oh sorry habbit. Another forum I am on, they tell you to code all links lol. I will take a look a renaming the peices etc and report back :)
Post Reply

Return to “Game Development”