.com.unity Forums

.com.unity Forums (http://forum.shrapnelgames.com/index.php)
-   Scenarios, Maps and Mods (http://forum.shrapnelgames.com/forumdisplay.php?f=146)
-   -   TOUGH Modding Questions (http://forum.shrapnelgames.com/showthread.php?t=42841)

NTJedi April 13th, 2009 01:51 AM

TOUGH Modding Questions
 
These are what I consider some tough modding questions, but hopefully the veterans will know.

1) Can you add a ranged weapon as a secondary effect for a melee weapon?
So far it's not working. The reason is so I could have an effect which only occurs once every two turns or even less frequently.

2) How can I create a spell which drops a long range assassin already in stealth on an enemies province?
I know the wild boar spell already drops an independent stealthy unit which needs to be found. I would like to create a similiar spell which drops an assassin owned by the caster and without the wild boar event pop_up message.

3) Has anyone tried using the RAND command?
I found RAND was one of the hidden commands... which has me very interested since it's probably used for RANDOM percentages. I've tried a few modding combinations using RAND yet no luck.
Probably doesn't exist per Ich

lch April 13th, 2009 02:36 AM

Re: TOUGH Modding Questions
 
Quote:

Originally Posted by NTJedi (Post 685493)
I found RAND was one of the hidden commands...

Found how? It's not in the strings table, it is not being parsed by the game.

NTJedi April 13th, 2009 02:46 AM

Re: TOUGH Modding Questions
 
Quote:

Originally Posted by lch (Post 685494)
Quote:

Originally Posted by NTJedi (Post 685493)
I found RAND was one of the hidden commands...

Found how? It's not in the strings table, it is not being parsed by the game.

Found from the list of strings you posted on 10-25-07, 02:58 PM:
http://forum.shrapnelgames.com/showt...highlight=rand


Perhaps I read the thread too quickly.

lch April 13th, 2009 03:05 AM

Re: TOUGH Modding Questions
 
Quote:

Originally Posted by NTJedi (Post 685496)
Found from the list of strings you posted on 10-25-07, 02:58 PM:
http://forum.shrapnelgames.com/showt...highlight=rand

Ah. That was just single words from the strings table, of random text found in the game binary. Those can be used for entirely different things, like "randgod" is used as a debug message, for example.

At the moment I don't have the complete list of mod commands that are being parsed. But here is the table of complete map commands that are actually being parsed:
Code:

additem
allies
allowedplayer
bodyguards
cannotwin
clearmagic
commander
comname
computerplayer
defaultmapzoom
defence
defense
description
dom2title
dominionstr
domversion
feature
features
fort
god
imagefile
independents
killfeatures
knownfeature
lab
land
landname
mag_air
mag_astral
mag_blood
mag_death
mag_earth
mag_fire
mag_nature
mag_priest
mag_water
maptextcol
neighbor
neighbour
nohomelandnames
nonamefilter
nostart
owner
players
poptype
population
randomequip
scale_chaos
scale_cold
scale_death
scale_lazy
scale_unluck
scale_unmagic
scenario
setland
specstart
start
startspell
temple
terrain
title
units
unrest
victorycondition
victorypoints
wraparound
xp


NTJedi April 13th, 2009 03:31 AM

Re: TOUGH Modding Questions
 
Thanks Ich... this answers one of my questions.

lch April 13th, 2009 03:55 AM

Re: TOUGH Modding Questions
 
So, here are all the mod commands that are being parsed by the game:

Spells
Code:

aoe
clear
copyspell
damage
descr
effect
end
explspr
fatiguecost
flightspr
name
newspell
nextspell
nreff
path
pathlevel
precision
range
researchlevel
restricted
school
selectspell
sound
spec

Items
Code:

armor
constlevel
copyspr
descr
end
mainlevel
mainpath
name
newitem
secondarylevel
secondarypath
selectitem
type
weapon

Nametypes
Code:

addname
clear
end
selectnametype

Nations
Code:

addreccom
addrecunit
autoundead
bloodnation
brief
castleprod
clearnation
clearrec
clearsites
color
deepfort
defaultfort
defcom1
defcom2
defmult1
defmult1b
defmult2
defmult2b
defunit1
defunit1b
defunit2
defunit2b
descr
domkill
domunrest
dyingdom
end
epithet
era
farmfort
flag
forestfort
hero1
hero2
hero3
hero4
hero5
hero6
horsereanim
idealcold
indepflag
labcost
manikinreanim
mountainfort
multihero1
multihero2
name
nametype
nodeathsupply
nopreach
sacrificedom
selectnation
startcom
startfort
startscout
startsite
startunitnbrs1
startunitnbrs2
startunittype1
startunittype2
summary
swampfort
templecost
templepic
tombwyrmreanim
uwfort
uwnation
wightreanim
zombiereanim

Sites
Code:

clear
com
decscale
end
gems
gold
homecom
homemon
incscale
level
loc
mon
name
newsite
path
rarity
res
selectsite

Misc

Code:

coldincome
coldsupply
deathdeath
deathincome
deathsupply
eventisrare
luckevents
misfortune
poppergold
researchscale
resourcemult
slothincome
slothresources
supplymult
turmoilevents
turmoilincome
unresthalfinc
unresthalfres


Aezeal April 13th, 2009 05:26 AM

Re: TOUGH Modding Questions
 
NT, I don't have teh DB/spell Db here now but basicly you can just look in that one and use the spelleffect numbers from a spell that matches. I've not tries a remote assassin yet but for other spells it works well. If you know what spell you want to base it on it should be pretty easy to look up and just change the damage number in the unit you want there.

But as I said I've not actually tried it.. it worked for regular summon and a combination of friendly farsummons though.

While looking through the spell DB I noticed there are acutally a few spells which I though where pretty much alike with different spelleffect numbers so you might want to look at the exact spell you want to replicate.

Aezeal April 13th, 2009 05:27 AM

Re: TOUGH Modding Questions
 
and on 1 I'd guess it's not possible certainly if you've already tried it a bit (I don't think there would be many way's you could code it so if it doesn't work it probably just doesn't work)

NTJedi April 13th, 2009 01:47 PM

Re: TOUGH Modding Questions
 
Quote:

Originally Posted by Aezeal (Post 685516)
NT, I don't have teh DB/spell Db here now but basicly you can just look in that one and use the spelleffect numbers from a spell that matches. I've not tries a remote assassin yet but for other spells it works well. If you know what spell you want to base it on it should be pretty easy to look up and just change the damage number in the unit you want there.

I could copy the wild boar spell, but how would I make sure the owner will not be independent also how would I prevent the pop-up event message associated.
Another angle to workaround the above two problems would be how could I make the commander land within an enemy province already in stealth mode.

Aezeal April 13th, 2009 03:34 PM

Re: TOUGH Modding Questions
 
nono not COPY the spell use the CODE that is given in the spell DB. But if the wild boar is neutral and you want a NOT neutral summon than you can;t look at his CODE since then you'll just get another indep summon I'd say. You need to use a code that gives the result you want, so use it of a spells that does what you want.
PS I've got no idea where the messages go so maybe that is unavoidable anyway.

Aezeal April 13th, 2009 03:44 PM

Re: TOUGH Modding Questions
 
For example.

The spell monster boar has:
effect 10042 (the same as dream horror btw, I think they are both indep stealth spells right, never used them)

10000 means ritual, and 42 means send event

the damage is 11 and 12 on those spells which means that the damage CANNOT mean the unit number which it usually is with summon spells.

I guess that means you can't just replace a unit number and use the same effect.

The send assassin spells use 10050 (eg send tupilak (don't know that one) and infernal disease (never used it htough) and there you can use a unit number as damage (I think).. but then you would just have a remote assasin spell not one hidden.

rdonj April 17th, 2009 05:43 PM

Re: TOUGH Modding Questions
 
A friend of mine is having a weird problem with one of his mods.

Code:

#newmonster 2702
#name "Lesser Daemon"
#copyspr 1268
#descr "A low level daemon."
#ap 12
#mapmove 2
#hp 12
#prot 0
#size 2
#str 11
#enc 3
#att 10
#def 10
#prec 10
#mr 10
#mor 10
#gcost 10
#rcost 0
#weapon 601
#Weapon 627
#armor "Four Word Long Name"
#armor "Four Word Long Name"
#maxage 400
#fireres 60
#neednoteat
#demon
#okleader
#nomagicleader
#noundeadleader
#nametype 102
#end

The problem with this unit is that it is supposed to be dual wielding, but when you look at it in game it can only use one weapon. We've tried a number of things to make it work but we can't figure out any way for it to dual wield, no matter what weapons we try to give it. Is the problem somewhere in its stats? Where else should we be looking to try and fix this problem? Any help would be appreciated, this is driving us crazy....

NTJedi April 17th, 2009 06:18 PM

Re: TOUGH Modding Questions
 
looks like it needs #ambidextrous 1

rdonj April 17th, 2009 06:22 PM

Re: TOUGH Modding Questions
 
Tried it... doesn't help :(

Aezeal April 17th, 2009 07:28 PM

Re: TOUGH Modding Questions
 
is any of those armors a shield? is any of the weapons 2 handed? does something else show up whcih would occupy a hand?

Aezeal April 17th, 2009 08:07 PM

Re: TOUGH Modding Questions
 
#newitem
#name "Blaster"
#descr "The blaster is a basic ranged weapon used all around the galaxy."
#constlevel 0
#mainpath 3
#mainlevel 1
#secondarypath -1
#type 3
#weapon 701
#copyspr 16
#end

why is this not showing I wonder (the copyspr is a copy of just mans cross since Ivé not seen a command to add new sprites)

it's level 0, earth magic so should show and be forgable by any with earth magic and a few gems.. doesn't show though.

rdonj April 17th, 2009 08:13 PM

Re: TOUGH Modding Questions
 
Quote:

Originally Posted by Aezeal (Post 686412)
is any of those armors a shield? is any of the weapons 2 handed? does something else show up whcih would occupy a hand?

Nope, it's a helmet and body armor. The weapons are both one handed, and we've tried using vanilla weapons in their place. For example, giving the unit a spear and a dagger makes it use just a spear. It's also not a conflict with other mods, we made sure to rule that out early.

Calchet April 17th, 2009 09:04 PM

Re: TOUGH Modding Questions
 
You capitalised the "W" of the second #weapon, though I dunno if that'd cause it to not work. Try making it lower-case, either way.

Let's see... perhaps it might be connected to itemslots somehow? Try assigning a value with two or more hand slots and see if that works.

Other than these things, I can only suggest you refer to the weapons by name rather than number, as that's what I've always done, though I don't think that'd cause problems.

I also pasted a random unit from a mod of mine that properly dual-wields one-handed weapons below, in case you can spot any differences I've missed.

Code:

#newmonster 2905
#spr1 "./fate/archer_2.tga"
#spr2 "./fate/archer_2_attack.tga"
#name "Archer"
#descr "A hero of myth or legend summoned to do fight at your side. Archer is not a class suited for melee combat, and this individual is no exception. He serves best off the battle field, and has the ability to create magical items with almost no materials by pulling them from an internal 'world'. When forced to do battle, he fights using a pair of flawless blades created anew for each attack, and a magical shield likewise 'projected' to block most missiles. He has unrivalled precision, as befitting his class."
#onebattlespell "Air Shield"
#ap 20
#mapmove 2
#hp 70
#prot 4
#size 2
#unique
#str 11
#enc 1
#att 17
#def 20
#prec 33
#mr 15
#mor 30
#gcost 0
#rcost 0
#weapon "Kanshou"
#weapon "Bakuya"
#armor "Coat"
#eyes 2
#startage 40
#maxage 370
#ambidextrous 12
#forgebonus 100
#coldres 25
#fireres 25
#shockres 100
#poisonres 25
#itemslots 15494
#magicskill 0 3
#magicskill 1 3
#magicskill 2 2
#magicskill 3 3
#poorleader
#poormagicleader
#noundeadleader
#end


Burnsaber April 17th, 2009 10:55 PM

Re: TOUGH Modding Questions
 
It's the capital letter "W" in the second "Weapon" - line. Lowercase it (to "#weapon"), and then it should work.

I've been struck by this multiple times.

Aezeal April 18th, 2009 05:00 AM

Re: TOUGH Modding Questions
 
anyway is there really no way to get a new sprite in for the weapons... I mean.. there isn't really anything that really looks like a gun of any kind in the game.

and I still like to know why it doesn't work :D

rdonj April 18th, 2009 05:08 AM

Re: TOUGH Modding Questions
 
Well, you guys were right, that fixed it. I would feel like such an idiot right now, except for the fact that I was staring at it in notepad and the capital W looks almost identical to the lower case W in that program under default font. So thanks for helping me out with that. Sometimes a fresh set of eyes really comes in handy.

Aezeal - Didn't you at one point have an item called "repair droids" or some such? I know I saw it as a forgable item, I think it was an earth item also. So I'm not sure why it wouldn't even show up. I have no idea about your other question.

Aezeal April 18th, 2009 05:43 AM

Re: TOUGH Modding Questions
 
repair droids is a ring of regen with a namechange.


All times are GMT -4. The time now is 12:07 AM.

Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©1999 - 2025, Shrapnel Games, Inc. - All Rights Reserved.