[Tote] Commands not specified anywere

Maps and the art of mapmaking.
User avatar
Jonas
Conscript
Conscript
Posts: 219
Joined: 14 Jan 2009

[Tote] Commands not specified anywere

Unread postby Jonas » 17 Feb 2009, 22:22

There are some commands in the editor that is not specified in either the manual and on this forum. I have tried them all but only got a few answers. :wall: Have anyone else got a grip of them?

Code: Select all

CalcAverageMonstersTier();
Tried with heroName, objectName, but just got errors

Code: Select all

CreateTreasure("scriptName", TYPE, count, x, y, floor;)
It works partly. It creates a treasure, but not the right one (6=WOOD, 2=GOLD, etc). It even seems to miss one o more factors 'cause it displays an error even if the treasure itself is created correctly.

Code: Select all

GetGuardsTier("scriptName");
Returns an array in whitch I can't get the pattern. It seems that it have something to do with uppgrades. :?

Code: Select all

GetObjectNamesByType();
Returned an empty table, maybe only because I couldn't find the right "Type" as statement.

Code: Select all

GetObjectsFromPath();
What could this be good for?

Code: Select all

GetStandState();
GetStandStatesCount();
SetStandState();
Did just get errors from testing in cosole.

Code: Select all

GetTerrainSize();
Returns map-size; 72,72 and so on.

Code: Select all

IsTilePassable(x, y, floor);
Returns nil if not passable and 1 if passable.

Code: Select all

OverrideAdvMapDialogPos
;|

Code: Select all

StopTrigger
Didn't try it. Guess it's the same as set a trigger to nil.
:leo: A man who carries a cat by the tail learns something he can learn in no other way.
Mark Twain

Franzy
War Dancer
War Dancer
Posts: 362
Joined: 07 Sep 2007
Location: Moscow, Russia
Contact:

Re: [Tote] Commands not specified anywere

Unread postby Franzy » 18 Feb 2009, 09:04

Code: Select all

CalcAverageMonstersTier();
Returns an average level of neutral creatures on the map (can be not an integer).

Code: Select all

CreateTreasure("scriptName", TYPE, count, x, y, floor;)
Never tried this one.

Code: Select all

GetGuardsTier("scriptName");
Possibly returns levels of creatures in the garrison.

Code: Select all

GetObjectNamesByType();
I guess it's an alias of GetAllNames( nFilterCode ). As it returns a string, it's for debugging purposes only.

Code: Select all

GetObjectsFromPath();
Returns an array of object, hero will pass by on his way to destination. Good for programming AI. Full sintaxis:
tsObjects GetObjectsFromPath( sHeroName, nX, nY, nFloorID = -1 )

Code: Select all

GetStandState();
GetStandStatesCount();
SetStandState();
Stand - is a state of an object. I think in the beginning devs thought their objects would have several states which you can change in the game. Every state could have a different look and behaivior. For example, unvisited Elven Garden would show a dancing leprechon, and visited - no leprechon (as in previous games). In the end they skipped this idea, sticking to different effects instead. Now there is only ONE object that has states - Tieru's Hut (rock with tieru, empty rock).

Code: Select all

StopTrigger
Didn't try it. Guess it's the same as set a trigger to nil.[/quote]

This function should be avoided totally, it's buggish.

User avatar
Jonas
Conscript
Conscript
Posts: 219
Joined: 14 Jan 2009

Unread postby Jonas » 18 Feb 2009, 13:56

Thanks for your answer Franzy. It's just interesting to know the behaviors of the commands if they should be needed. :)

EDIT :P
Interesting to hear about the state-command. Maybe I shall try to make a mod (safe :D ) of an object with added state-lines in the properties xdb-file. Even if it's a time-consuming operation to change objects like this, it open up a lot of possibilities to change the look of the map during play.
:leo: A man who carries a cat by the tail learns something he can learn in no other way.
Mark Twain

edwin_yang
Leprechaun
Leprechaun
Posts: 10
Joined: 23 Jan 2009

Unread postby edwin_yang » 19 Feb 2009, 04:31

How about the SetObjectiveProsses() function? I think it is like the print() function just be used for testing the map. didnt know the real use of this function ;|

Franzy
War Dancer
War Dancer
Posts: 362
Joined: 07 Sep 2007
Location: Moscow, Russia
Contact:

Unread postby Franzy » 19 Feb 2009, 08:23

You must be kidding. This is a very important function if you use multistaged objectives (usually manual). Open any objective and find property ProgressMessages. There you can specify any number of progress messages (stages) to mark player's progress in the quest.

edwin_yang
Leprechaun
Leprechaun
Posts: 10
Joined: 23 Jan 2009

Unread postby edwin_yang » 19 Feb 2009, 09:05

Thanks,will try it . but I never seen the messageboxes showed up when use this function,and when I start a multistep objective I usually use SetObjectiveStat( COMPLETED ) to end the last step and SetObjectiveStat( ACTIVE ) to start the next step... :)


Return to “Mapmaking Guild”

Who is online

Users browsing this forum: No registered users and 1 guest