Dear forum users! In compliance with the new European GDPR regulations, we'd just like to inform you that if you have an account, your email address is stored in our database. We do not share your information with third parties, and your email address and password are encrypted for security reasons.

New to the forum? Say hello in this topic! Also make sure to read the rules.

Client-Side

Here you can find ScriptAPI suggestions implemented in the game.
Forum rules
By using the forum you agree to the following rules.
Locked
User avatar
Ortimh
Fighter
Fighter
Posts: 34
Joined: Mon Apr 11, 2016 7:47 am
SFD Alias: Unknown
Started SFD: Pre-Alpha 1.2.1
Location: Indonesia
Gender:

Client-Side

Post by Ortimh » Mon May 09, 2016 11:40 am

Can you at least add methods for clients? This is what I've been thinking so far.

I'd like to see these methods in IGame class.

Code: Select all

abstract IPlayer GetPlayer(int PlayerID) // Gets a player with provided ID
abstract IUser GetUser(int UserID) // Gets a use with provided ID
Or at least methods that does technically the same thing.

I'd like to see these methods in IUser class.

Code: Select all

abstract Vector2 GetCameraPosition() // Gets the user's camera position in map
abstract Vector2 GetCameraScale() // Gets the user's camera scale
Or maybe a new ICamera class for itself?
Off Topic
And could you please add "when a player spawns" and "when a player kills" listeners?
0 x

User avatar
Gurt
Lead Programmer
Lead Programmer
Posts: 1329
Joined: Sun Feb 28, 2016 3:22 pm
Title: Lead programmer
Started SFD: Made it!
Location: Sweden
Gender:
Age: 28

Post by Gurt » Mon May 09, 2016 9:36 pm

The ScriptAPI will get some minor new stuff in the next update including:

Code: Select all

IObject Game.GetObject(int uniqueID) // Unique id form IObject.UniqueID
IPlayer Game.GetPlayer(int uniqueID) // Unique id form IPlayer's base IObject.UniqueID
IUser Game.GetActiveUser(int userIdentifier) // id from IUser.UserIdentifier
1 x
Gurt

Locked

Who is online

Users browsing this forum: No registered users and 1 guest