Jump to content

  • Log In with Google      Sign In   
  • Create Account


- - - - -

AngelScript 2.26.3 is out


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
6 replies to this topic

#1 Andreas Jonsson   Moderators   -  Reputation: 3198

Like
5Likes
Like

Posted 08 May 2013 - 07:29 PM

In this release I've implemented support for delegates, which is an extension of the previously available function handles. With delegates it is now possible to pass class methods as callbacks where an ordinary function handle is expected.

 

I've also finally taken the time to implement recursive search for symbols in parent namespaces. This should make the namespace feature much easier to use as you'll no longer have to prefix all the global symbols when compiling a function in a namespace.

 

The engine has a new property to allow an application to disable support for value assignments for reference types. While this may sound like a something bad, it is actually making the language less ambiguous when dealing with reference types. Too often do script writers make a value assignment when they actually intended to make a handle assignment.

 

The script builder add-on now also have methods to enumerate the script sections that were included in a module. This is an useful feature when caching the compiled bytecode, as you'll now know which files to check for updates in.

 

And finally I added a couple of add-on functions for doing a direct conversion from float to int, called fpToIEEE and fpFromIEEE. These are meant to be platform agnostic so they'll work even if the CPU where the script is running isn't using the IEEE standard natively to represent floating point values.

 

Regards,

Andreas


AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game

Sponsor:

#2 Oscar1   Members   -  Reputation: 115

Like
0Likes
Like

Posted 09 May 2013 - 09:11 PM

Thanks, fantastic work. The asEP_DISALLOW_VALUE_ASSIGN_FOR_REF_TYPE is definitelly going to be set TRUE in my project


Edited by Oscar1, 09 May 2013 - 09:12 PM.


#3 glcolor   Members   -  Reputation: 158

Like
0Likes
Like

Posted 14 May 2013 - 09:33 AM

Great,thanks,I waited delegate for a long time,and I hope the @ symbol can be removed completely from the language as soon as possible,I was confused by it frequently...



#4 FDsagizi   Members   -  Reputation: 514

Like
0Likes
Like

Posted 16 May 2013 - 09:55 AM

i have small question, how use array sorting, with ref type ?

Edited by FDsagizi, 16 May 2013 - 09:55 AM.


#5 Andreas Jonsson   Moderators   -  Reputation: 3198

Like
0Likes
Like

Posted 17 May 2013 - 07:06 PM

@glcolor:

 

I'm not sure I will remove it completely, but if I do it will only happen when I start working on AngelScript 3.0.

 

@FDsagizi:

 

You mean when you have something like:

 

array<obj@> arr;
arr.sort();

 

It's unfortunately currently not possible. Currently the CScriptArray will sort the handles by the address, rather than calling the opCmp method on the object, which is rather stupid. I don't know what I was thinking when I implemented it that way. But don't worry, I'll have it changed soon. cool.png


AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game

#6 Andreas Jonsson   Moderators   -  Reputation: 3198

Like
0Likes
Like

Posted 18 May 2013 - 09:17 AM

I changed the array yesterday to allow it to sort on arrays of handles too. The code is in revision 1641.


AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game

#7 FDsagizi   Members   -  Reputation: 514

Like
0Likes
Like

Posted 20 May 2013 - 10:03 PM

Surep! allways - engine->SetEngineProperty( asEP_DISALLOW_VALUE_ASSIGN_FOR_REF_TYPE , true ); smile.png

by the way if asEP_DISALLOW_VALUE_ASSIGN_FOR_REF_TYPE  == true then '@' not actual!

Thanks!






Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS