Post news RSS Modding V2!

Small Improvements and Bugfixes for DUSK + Modding API fixes!

Posted by on

title 2

SMALL MODDING UPDATE

Today we launched a small API Update for our DMA [Dusk Modding API]


20170411193545 1


<<Classnames: DBuilding, GameTime, Player, Inventory>>

>

DBuilding Class:

	Building Types {Farm,Forge,Barn,Wall,Tower,Lab}
	//Lab not Implemented yet

	public string getType(int Type) > returns Building Type //Deprecated - Will be changed next time!

	public void setType(float xPos, int Type) > sets Building Type

	public void delType(float xPos, GameObject obj) > delets Building

        public Hashtable getBuildings() > returns Hashtable of all Buildings


GameTime Class:

	public float getTime() > returns Time of Day

	public void setTime(int time) > sets Time of Day

	public void addTime(int time) > adds int x to Time of Day

	public void delTime(int time) > removes int x from Time of Day

	public void setDay(int day) > sets Daycount

	public int getDay() > get Daycount


Inventory Class:

	Item Types {Wood,Stone,Metal,Ammo,Coins}

	public void setAmount(Types s, int amount) > sets amount of specific Item

	public void addAmount(Types s, int amount) > adds amount to specific Item

	public void delAmount(Types s, int amount) > deletes amount to specific Item

        //Instead of Type S you can use an Integer (0-4) to specifiy the Item


Player Class:

	//Player.name is no longer public

	public GameObject gObj; > Player Object

	public Player getPlayer(string pName) > gets Player by Name (Default: "Player")

	public float getPos() > gets Playerposition

	public void setPos(float x) > sets Playerposition

	public string getName() > gets Playername

	public void setName(string s) > sets Playername

	public int getNID() > gets NetworkID

	public void setNID(int id) > sets NetworkID

	public int getSpeed() > gets Speed

	public void setSpeed(int s) > sets Speed



If you got any suggestions for our DMA [Dusk Modding API]

put it in the comment section!

Post a comment
Sign in or join with:

Only registered members can share their thoughts. So come on! Join the community today (totally free - or sign in with your social account on the right) and join in the conversation.