.com.unity Forums
  The Official e-Store of Shrapnel Games

This Month's Specials

BCT Commander- Save $6.00
World Supremacy- Save $10.00

   







Go Back   .com.unity Forums > Illwinter Game Design > Dominions 3: The Awakening > Scenarios, Maps and Mods

Reply
 
Thread Tools Display Modes
  #1  
Old April 12th, 2012, 01:25 PM
Ragnarok-X's Avatar

Ragnarok-X Ragnarok-X is offline
Major General
 
Join Date: Jan 2004
Location: Germany / Bielefeld
Posts: 2,035
Thanks: 33
Thanked 18 Times in 12 Posts
Ragnarok-X is an unknown quantity at this point
Default Re: UnitGen - Random nations with procedural sprites!

Code:
#newitem
#name "tiger"
#gameid -1
#sprite /graphics/mounts/standard/tiger.png
#armor
#offsetx -4
#offsety 4
#define "#size 3"
#define "#mapmove 2"
#define "#ap 18"
#define "#mounted"
#define "#weapon 19 --- Bite"
#define "#gcost +35"
#define "#ressize 2"
#define "#enc 3"
#define "#rcost +5"
#theme "animal serpent"
#theme "light"
#tag "guaranteedprefix serpent"
#tag "maxprot 13"
#enditem
This is what i added.
I then did put a barechest guy with spear on top of it.
the unit def turned out like this>

Code:
--- Unnamed, Gold: 40, Resources: 9
#newmonster 0
#name "Unnamed"
#spr1 ".unit_0_a.tga"
#spr2 ".unit_0_b.tga"
#descr "No description"
#gcost 40
#ap 18
#mapmove 2
#mor 10
#mr 10
#hp 10
#str 10
#att 10
#def 10
#prec 10
#enc 3
#size 3
#mounted
#weapon 352
#ressize 2
#rcost 5
#armor 118 --- Half Helmet
#weapon 1 --- Spear
#end
Now, i think this is wrong. Its missing the bite attack and a potential stat increase for being mounted. What am i missing _
thanks
Reply With Quote
  #2  
Old April 12th, 2012, 04:23 PM
Ragnarok-X's Avatar

Ragnarok-X Ragnarok-X is offline
Major General
 
Join Date: Jan 2004
Location: Germany / Bielefeld
Posts: 2,035
Thanks: 33
Thanked 18 Times in 12 Posts
Ragnarok-X is an unknown quantity at this point
Default Re: UnitGen - Random nations with procedural sprites!

I added tiger, jaguar and wyvern.
Unfortunally the wyvern sprite doesnt show the FACE of the base human.
why not ? I aligned the sprite of the wyvern on top of the pegasus rider, so the offset is correct.

Will you include the edits from earlier (where i posted in code) in the next build ?
Because if not, i wont bother to post all the stuff in this thread, thanks.
If you, i can upload the sprites and altered .txts entirely or just in code-tags like earlier.
In addition, do you want my "help" / posting in here or on the dom3mods ?


dont mind with the attachments, i forgot to add weapon with the nostrength tag to the mounts. But you can check the problem witht he wyvern if you would.
The files in general work, i just got a tiger rider to spawn in a nation.
Attached Files
File Type: rar mounts.rar (8.2 KB, 126 views)

Last edited by Ragnarok-X; April 12th, 2012 at 04:37 PM..
Reply With Quote
  #3  
Old April 12th, 2012, 05:29 PM

elmokki elmokki is offline
Second Lieutenant
 
Join Date: Aug 2008
Posts: 408
Thanks: 11
Thanked 209 Times in 57 Posts
elmokki is on a distinguished road
Default Re: UnitGen - Random nations with procedural sprites!

The wyvern problem is not because of you, apparently it's because of a bug that affected the hoburg hawk riders earlier too. I fixed it any from next version on it should look fine. The wyvern, however, probably needs an overlay to not look silly (you'll probably see once it's fixed and use big shield and big weapon). If you really want to get this fixed quick, go to races/human/poses.txt and add the line:

#renderorder "shadow cloakb mount basesprite shirt legs armor cloakf bonusweapon weapon offhandw hands hair helmet offhanda overlay"

to both mounted poses, ie after the #newpose line obviously.

In general, good job. They look good and seem to be positioned correctly too. Your item definition code looks good and it DOES add the bite attack when I tested it. Your unit has #weapon 352 which is the boar #nostr gore attack, so maybe you did some mistake? The unit price is lower than supposed probably because it's naked and gets the -30% cost reduction and is rounded to closest 5 afterwards.

Code:
#newmonster 0
#name "Unnamed"
#spr1 ".unit_0_a.tga"
#spr2 ".unit_0_b.tga"
#descr "No description"
#gcost 30
#ap 18
#mapmove 2
#mor 10
#mr 10
#hp 10
#str 10
#att 10
#def 10
#prec 10
#enc 3
#size 3
#mounted
#weapon 322
#ressize 2
#end
This is also adding these items to unitgen. With your files occasionally it would indeed generate units with those mounts. I forgot to mention that at the moment you can use #skipchance 0-100 to make mounts rarer. #skipchance 100 means it will never be generated, #skipchance 50 makes it a 50% chance to skip over the mount. This system will change eventually if I can be arsed to code though, since everything else uses a system where you write the chances differently and it's a better system.

You'll also probably want to use the #theme "animal serpent" correctly (and pretty much all the possible minimum and maximum armor things too), ie #theme "animal tiger" for tiger, otherwise you'd see tigers bundled with serpents very often. You'll also probably want to add a claw attack to the tigers since I think they have both claw and bite in Dom3.

I don't care which forum you post on, but I do prefer code tags instead of whole files since that way I can just copy paste the new stuff without worrying it replaces something I've changed recently.
__________________
UnitGen - randomly generated nations with randomly generated sprites
http://forum.shrapnelgames.com/showthread.php?t=48341
Reply With Quote
  #4  
Old April 13th, 2012, 12:04 PM
Ragnarok-X's Avatar

Ragnarok-X Ragnarok-X is offline
Major General
 
Join Date: Jan 2004
Location: Germany / Bielefeld
Posts: 2,035
Thanks: 33
Thanked 18 Times in 12 Posts
Ragnarok-X is an unknown quantity at this point
Default Re: UnitGen - Random nations with procedural sprites!

Thanks for the update.
Regarding #skipchance, thanks for letting me know. However, i dont plan on using it anytime soon since i actually had to create 4 batches of 10 nations until the tiger showed up. If at all, i need a way to increase the spawn.
I asumme i can set the tiger to "animal tiger" and use "preferredmount tiger" in the nation files, or do new pref-mounts dont work, i.e. is it hardcoded for serpent, horse, boar and stuff ?

Regarding min/max protection, am i right in assuming its referring to the base units prot values ? i.e. using only maxprot 15 will force the game to ONLY spawn this mount if the mounted unit has a prot no higher than 15 ?
If so, what will it do if the mounted unit has a prot outside the mounts specified value ?

Lastly, can you elaborate on the "naked unit" thingy again ? What exactly is wrong with it ? Do you mean the units price is too low and i need to add a certain to the mount ?

Then, what is your stance on secondshape ?
Horse units, when killed, dont spawn the horse. Lizards and snakes however create the animal unit once the rider is killed.
How do YOU want it to be with tigers, jaguars, wyvern (and im going to add bears and nightmares later) ? Should they have a secondshape on death or not ?


Can you be found in IRC or some messenger more regulary than on this forum ?
Can you release a new version of spritegen with the fixed wyvern bug so i can continue adding things on a updated version ?
Reply With Quote
  #5  
Old April 13th, 2012, 01:28 PM

kianduatha kianduatha is offline
Second Lieutenant
 
Join Date: Jun 2009
Posts: 403
Thanks: 15
Thanked 28 Times in 21 Posts
kianduatha is on a distinguished road
Default Re: UnitGen - Random nations with procedural sprites!

Quote:
Originally Posted by Ragnarok-X View Post
Thanks for the update.
Regarding #skipchance, thanks for letting me know. However, i dont plan on using it anytime soon since i actually had to create 4 batches of 10 nations until the tiger showed up. If at all, i need a way to increase the spawn.
I asumme i can set the tiger to "animal tiger" and use "preferredmount tiger" in the nation files, or do new pref-mounts dont work, i.e. is it hardcoded for serpent, horse, boar and stuff ?

Regarding min/max protection, am i right in assuming its referring to the base units prot values ? i.e. using only maxprot 15 will force the game to ONLY spawn this mount if the mounted unit has a prot no higher than 15 ?
If so, what will it do if the mounted unit has a prot outside the mounts specified value ?

Lastly, can you elaborate on the "naked unit" thingy again ? What exactly is wrong with it ? Do you mean the units price is too low and i need to add a certain to the mount ?

Then, what is your stance on secondshape ?
Horse units, when killed, dont spawn the horse. Lizards and snakes however create the animal unit once the rider is killed.
How do YOU want it to be with tigers, jaguars, wyvern (and im going to add bears and nightmares later) ? Should they have a secondshape on death or not ?


Can you be found in IRC or some messenger more regulary than on this forum ?
Can you release a new version of spritegen with the fixed wyvern bug so i can continue adding things on a updated version ?
Elmokki can be found most of the time on IRC, the standard gamesurge #dominions channel.

I am fairly confident that whatever you prefer in terms of hte secondshape will be fine; if it turns out to be unbalanceable it'll be changed.

Naked/very lightly armored units get up to a 30% price decrease automatically because that rough idea is also present in baseline dom3. Light cav therefore automatically costs less than heavy cav and so on.

Max/minprot are there so you can say that naked people shouldn't be riding heavily barded horses--currently horse cav is split up into light cav(unarmored horses) medium(like light cataphracts etc) and heavy, each with even their own equipment sets(to prevent 'naked guy with a lance' etc. Protection values generally conform to the actual protection, i.e. after base prot and armor have been taken into account.
Reply With Quote
  #6  
Old April 13th, 2012, 04:06 PM

elmokki elmokki is offline
Second Lieutenant
 
Join Date: Aug 2008
Posts: 408
Thanks: 11
Thanked 209 Times in 57 Posts
elmokki is on a distinguished road
Default Re: UnitGen - Random nations with procedural sprites!

http://koti.kapsi.fi/elmokki/dom3/un...en_13_4_12.zip

I'll probably forget something but:
- SpriteGen gets a x/y sliders for mount offsets. This is purely cosmetical and meant to help getting mount sprites to correct places. Won't happen for other items for now because that's slightly more problematic.
- UnitGen accepts seeds. It should theoretically generate the same set of nations if you create a mod with same amount of nations and
- Item #skipchances have been replaced with the #basechance commands which work like filters, ie if you don't specify anything item's weigth for randomizing is 1, if you specify something, that is used. And item has chance of weight/(all weights) to be chosen.
- Tweaks. Bonus weapons seemed somewhat broken so I fixed them. Also gave Abysians a special feature which should make bonus weapons on them more common even with a bit heavier armor.
- Only tengu commanders and sacreds get the lightning strike. This is a special racial command too and customizable
- Added settings.txt where you can edit some settings. More editable stuff will probably come eventually.
- Added a pile of mounts for humans by Ragnarok-X
EDIT: Sacred commanders should also be able to get H1 occasionally.

It crashes occasionally (but is very usable anyway since it isn't that common) on generation, gonna fix it later.
__________________
UnitGen - randomly generated nations with randomly generated sprites
http://forum.shrapnelgames.com/showthread.php?t=48341
Reply With Quote
  #7  
Old April 14th, 2012, 12:16 PM

elmokki elmokki is offline
Second Lieutenant
 
Join Date: Aug 2008
Posts: 408
Thanks: 11
Thanked 209 Times in 57 Posts
elmokki is on a distinguished road
Default Re: UnitGen - Random nations with procedural sprites!

http://koti.kapsi.fi/~elmokki/dom3/u...en_14_4_12.zip

Raiel had the awesome notion of giving a possibility of generating each nation with a separate seed. This was a brilliant idea, since now we have a concept for one more cheat preventing multiplayer method: allow players generate nations until they find one they like and then just make a mod with all the seeds players have submitted. Alternatively you could use the old semi-blind selection but just generate like 200 nations and then build a new mod on their seeds. This feature is disabled by default but the .dm file will always contain randomly chosen nation seeds if you wish to reproduce your random nations later. You can enable this and some other new interface related stuff at settings.txt

Changelog roughly:
- More awesome new mounts for humans and hoburgs by Ragnarok-X, including for example ozelotl (the flying tiger), beast bat, amphithetre and moose.
- Some name/description stuff by Ragnarok-X
- Normal/sacred commanders sometimes (relatively often) get higher maximum leadership
- Mounted hoburgs can't get tower shields (such a huge change!)
- Settings.txt contains some stuff that may or may not make life easier
- You can generate mods with each nation having a different seed (see the above small wall of text)
__________________
UnitGen - randomly generated nations with randomly generated sprites
http://forum.shrapnelgames.com/showthread.php?t=48341
Reply With Quote
  #8  
Old April 14th, 2012, 03:48 PM

elmokki elmokki is offline
Second Lieutenant
 
Join Date: Aug 2008
Posts: 408
Thanks: 11
Thanked 209 Times in 57 Posts
elmokki is on a distinguished road
Default Re: UnitGen - Random nations with procedural sprites!

http://koti.kapsi.fi/~elmokki/dom3/u...14_4_12-v2.zip

Earlier version broke ranged naming, it's fixed now along with some other very minor fixes.
__________________
UnitGen - randomly generated nations with randomly generated sprites
http://forum.shrapnelgames.com/showthread.php?t=48341
Reply With Quote
  #9  
Old April 14th, 2012, 07:58 PM

elmokki elmokki is offline
Second Lieutenant
 
Join Date: Aug 2008
Posts: 408
Thanks: 11
Thanked 209 Times in 57 Posts
elmokki is on a distinguished road
Default Re: UnitGen - Random nations with procedural sprites!

http://koti.kapsi.fi/~elmokki/dom3/u...en_15_4_12.zip

Balanced the mounts a bit, sacred weapons get potentially a slightly smaller stat increase when they do (from 2 to 6 to 1 to 4 for melee) and tweaked sacred cap only chances (settings.txt!)
__________________
UnitGen - randomly generated nations with randomly generated sprites
http://forum.shrapnelgames.com/showthread.php?t=48341
Reply With Quote
  #10  
Old April 16th, 2012, 10:17 PM

jimbojones1971 jimbojones1971 is offline
First Lieutenant
 
Join Date: Jan 2011
Posts: 754
Thanks: 72
Thanked 12 Times in 11 Posts
jimbojones1971 is on a distinguished road
Default Re: UnitGen - Random nations with procedural sprites!

A few of questions:

1) How do I tweak it to get it to only generate nations for a particular race? I tried two things:
- setting the #basechance values in races.txt to 0.0 for nation's I didn't want (and either leaving the #basechance value for the nation I want as-is, or also increasing it to 1.0).
- removing all nations I don't want from the races.txt file, leaving only the one I want

Neither of these worked - both resulted in the game hanging in the "generating nations" step. Help! :-)

2) Are there any command line switches?

3) Is there any chance of getting a look at the source, to satisfy my curiousity about what you are doing and how you are doing it? How about if I beg?
Reply With Quote
Reply

Bookmarks


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


All times are GMT -4. The time now is 02:14 AM.


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