- Home /
This post has been wikified, any user with enough reputation can edit it.
Function can't be called
Yesterday night I got this code working but then I accidentally pressed CTRL + Z on a wrong script and I can't figure out what I destroyed by doing that..
When I'm trying to call a function on another script using:
Client.js
print("this is printed");
var player = Player.stringToPlayer("some text"); /*Where Player is the name
of the script and stringToPlayer is the name of public static function*/
Player.js
public static function stringToPlayer(playerData:String) : Player{
print("This is never printed?");
return new Player(playerData);
}
So it kind of gets stuck at the point where it calls another function.
Comment
There is no way someone can help you with this short snippet of your code ..
@felixpk but well that's pretty much everything I have done so far.. function stringToPlayer() just doesen't seem to do anything it should and everything gets stuck.
If you could please just post the entire classes, I could get an overview.