[ian-reeds-games] Re: About Transformation

  • From: "Craig Brett" <dmarc-noreply@xxxxxxxxxxxxx> (Redacted sender "craigbrett17@xxxxxxx" for DMARC)
  • To: ian-reeds-games@xxxxxxxxxxxxx
  • Date: Sun, 15 Mar 2015 12:23:28 +0000

Scripters do have access to a unit's inventory. I remember talking to someone about that before. I believe that happened before I even came onto being a dev on TB. Ian told me to try using unit.Inventory. Though I have just noticed that it's not in the scripting documentation, so I'll fix that.


Transformations will carry over any items in the unit's inventory to the new unit. So, if your old unit has a sword and so does your new one, the new unit will have two swords. This is by design though, as there's nothing to tell me that you want to lose this item. Take the example where you have a unit who has 5 healing potions. It then transforms into a unit with 2 healing potions to start with. You don't want to lose 3 healing potions just because you've transformed. That's why it works the way it does.

As for that message you're getting if a unit has no items, I can't replicate it. Are you sure you're using the latest version of my scripts? I've looked through my transformation item moving function and there's nothing there that should raise any objections if there's no items.

And did you say you'd equipped a unit? That shouldn't be possible.

On 15/03/2015 03:01, Monkey wrote:
Ah well. Thanks anyway though!

On 3/14/15, Victorious <dtvictorious@xxxxxxxxx> wrote:
Yup, sadly.

-----Original Message-----
From: ian-reeds-games-bounce@xxxxxxxxxxxxx
[mailto:ian-reeds-games-bounce@xxxxxxxxxxxxx] On Behalf Of Monkey
Sent: Sunday, March 15, 2015 10:50 AM
To: ian-reeds-games@xxxxxxxxxxxxx
Subject: [ian-reeds-games] Re: About Transformation

Ah. I see.
Still wouldn't work though, at least not with this particular unit, because
even if I exclude the fact that the new unit has different equipment than
the old one, when he upgrades he gains new stats, another two skills, and a
different sound/friendly type. And I don't believe you can change all of
those with effects, at least not yet.

On 3/14/15, Victorious <dtvictorious@xxxxxxxxx> wrote:
No, not unless you put transformation in your effect. A transformation
is accomplished through the old unit being swapped for a new one. The
old/original unit does not get removed by the effect. E.g level 1
health_inflict_mod 15

-----Original Message-----
From: ian-reeds-games-bounce@xxxxxxxxxxxxx
[mailto:ian-reeds-games-bounce@xxxxxxxxxxxxx] On Behalf Of Monkey
Sent: Sunday, March 15, 2015 10:31 AM
To: ian-reeds-games@xxxxxxxxxxxxx
Subject: [ian-reeds-games] Re: About Transformation

Would it make a difference though? I mean, wouldn't I still be
transforming my unit?

On 3/14/15, Victorious <dtvictorious@xxxxxxxxx> wrote:
Just give it a really long round number for duration like 1000. Its
kind of ugly, but it works.

-----Original Message-----
From: ian-reeds-games-bounce@xxxxxxxxxxxxx
[mailto:ian-reeds-games-bounce@xxxxxxxxxxxxx] On Behalf Of Monkey
Sent: Sunday, March 15, 2015 9:44 AM
To: ian-reeds-games@xxxxxxxxxxxxx
Subject: [ian-reeds-games] Re: About Transformation

Yeah, I thought one of you said something like that quite a while ago
but I wasn't entirely sure if that had changed by now.

Could you please give me an example?
I'm upgrading one unit after a certain amount of time...and I don't
want him to downgrade because of the duration.

On 3/14/15, Victorious <dtvictorious@xxxxxxxxx> wrote:
The transformation scripts can't be used with items currently,
because scripters don't yet have access to the items that are on a
unit so that that information can be saved over to the new
transformed unit.
Maybe something for a future dev release?

Can you see if you can achieve the same thing using effects and my
effects script?

-----Original Message-----
From: ian-reeds-games-bounce@xxxxxxxxxxxxx
[mailto:ian-reeds-games-bounce@xxxxxxxxxxxxx] On Behalf Of Monkey
Sent: Sunday, March 15, 2015 9:30 AM
To: ian-reeds-games
Subject: [ian-reeds-games] About Transformation

Hello,

I've noticed that when I'm transforming from one unit into another,
the skill says "You don't have any items." I have the new unit
unequipped by default because he gains certain attributes after
equipping his weapon and armor, otherwise he'd be holding them
already. And my old unit doesn't have any unequipped items. I gave
him an item temporarily and it does fix the message then...
Not sure if this was a bug or if it's intentional, but there you go!

Also, there's the thing about transformations not monitoring
items...like, if my unit were to unequip the axe that he wields and
then transform, I would have two of that axe. This is probably
something that currently can't be fixed though, right? Since you
might not be able to tell what he has by default and what he picked
up, so you don't know what he should carry with him through the
transformation,
if anything.

--
-Mew
__________
http://www.savethefrogs.com/


--
-Mew
__________
http://www.savethefrogs.com/


--
-Mew
__________
http://www.savethefrogs.com/





Other related posts: