theFarWilds.com
http://thefarwilds.com/forum/

Suggestions / help
http://thefarwilds.com/forum/viewtopic.php?f=14&t=1857
Page 1 of 1

Author:  angelatheist [ Wed Apr 14, 2010 10:35 am ]
Post subject:  Suggestions / help

I haven't been able to get addTokens() to work, i've tried things like addTokens("Range Token",2), addTokens("Range",2), and addTokens("Sleep",2); but it hasnt worked.

When a figure is taken, doesExist() returns false.

I had a very strange bug where an entity i created and undimmed would become aloft for some reason.

I noticed the AI was recently updated, I wonder if it would be possible to choose which AI a script would use.

Also I used to have problems where on a preset map my novice adventurer would always gain the same stat tokens. (adding a dimwitted manticore made the tokens more random). I dont know if this is still a problem with the new ai.

Suggestions:

It seems very easy to accidentally delete a script, a confirmation popup or undo button would be nice.

Two separate public script lists, one just for people who want to play scripts that does not show the code and one for example scripts.

For the sake of completeness some functions that someone might find useful:
Player location.getControler();
void ent.heal(int delta);
void ent.setAloft(bool aloft);
bool ent.isType(string typeName);
int ent.getStat(string statName);

These could also be card functions if someone wanted to use them in isDeckValid().
string ent.getDomain();
int ent.getCost();
string ent.getRarity();


For fun functions:
void ent.rename(string newName);
string player.getName();
void player.giveAcheivement(String name, String image) //restricted use
void ent.makeInvincible(bool true);

And if you're really lazy you can implement ent.setAbilities(); and have the players create the next set for you.

Author:  jed [ Wed Apr 14, 2010 12:54 pm ]
Post subject:  Re: Suggestions / help

Expanded the addToken description:

some common tokens: attack,maxhp,vision,speed,range
// also: age,work,entrench,sleep,vigor,spawn,soul,termite
// you can look in helpers/counters.xml for a complete list
// Example: ent.addToken("attack",1);
// it is case sensitive

> When a figure is taken, doesExist() returns false.
yeah it doesn't exist anymore

> I had a very strange bug where an entity i created and undimmed would become aloft for some reason.
Are you creating it from an aloft Location?

Quote:
I noticed the AI was recently updated, I wonder if it would be possible to choose which AI a script would use.

The scripts are using the same AI that the download client has. You want to be able to use the weaker Flash AI?

Quote:
Also I used to have problems where on a preset map my novice adventurer would always gain the same stat tokens. (adding a dimwitted manticore made the tokens more random). I dont know if this is still a problem with the new ai.


I'll fix this in the next patch.

> string player.getName();
The server doesn't actually have the player's name you can still display their name though by going:
string msg="{u,";
msg += player.getID();
msg += "}";
and sending msg to the client.

> bool ent.isType(string typeName);
this exists as isType(EnityType );

Let me know if you need any of the other functions and I'll add them.

Author:  queeshai [ Tue May 11, 2010 7:20 am ]
Post subject:  Re: Suggestions / help

// return the round number
int getRound();

// getters and setters should always be available. "add*" is fine, but unnecessary in the base API.
Player.setFlux( int flux );
Player.setGlory( int glory );
Entity.setToken( string token, int num );
Entity.setHealth( int health );

// aliases for getCurHealth and numTokens
int Entity.getHealth();
int Entity.getToken( string token );

// is this location visible to player p?
bool Location.isVisible( Player p );

// is this entity visible to player p? always true for global enchants.
bool Entity.isVisible( Player p );

Author:  queeshai [ Tue May 18, 2010 4:46 am ]
Post subject:  Re: Suggestions / help

// domain of card, e.g., "sylvan" or "unaligned"
string Card.getDomainType();

// number of domains to cast
string Card.getDomainNum();

// casting cost of card
int Card.getFlux();

Page 1 of 1 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/