ScriptUO

Scripting Resources & Utilities => Stealth Client => Stealth archive => Topic started by: rwo001 on November 30, 2013, 08:09:57 PM

Title: How to use Script_GetPathArray (C#)
Post by: rwo001 on November 30, 2013, 08:09:57 PM
Code: [Select]
TMyPoint[] _path = Stealth.Script_GetPathArray(1011, 513, false, 0);
Console.WriteLine(_path.Length);
// Result : 0;
I can use Stealth.Script_MoveXY to move to the location but i can't get the path array..
Title: Re: How to use Script_GetPathArray (C#)
Post by: Orich on November 30, 2013, 09:06:59 PM
Nice to have someone testing out C# methods..  You are the first one to do it :)

These two functions :

Script_GetPathArray
and
Script_GetPathArray3D

I think they need a small fix in Stealth.exe.   I will update you ASAP
Title: Re: How to use Script_GetPathArray (C#)
Post by: rwo001 on November 30, 2013, 10:27:02 PM
Nice to have someone testing out C# methods..  You are the first one to do it :)

These two functions :

Script_GetPathArray
and
Script_GetPathArray3D

I think they need a small fix in Stealth.exe.   I will update you ASAP
Oh..Thanks Orich.

I'm current working on convert my OpenEUO LUA code to C#.... :P
Title: Re: How to use Script_GetPathArray (C#)
Post by: Orich on December 01, 2013, 03:19:09 AM
https://bitbucket.org/Stealthadmin/stealth-beta-client/downloads#download-273630


Looks like I fixed it ... what a stupid bug

Can you check it out?
Title: Re: How to use Script_GetPathArray (C#)
Post by: rwo001 on December 01, 2013, 08:43:59 PM
..It still have problem... :'(

// Current Position 1011,510;
TMyPoint[] _path = Stealth.Script_GetPathArray(1011, 508, false, 0);
Console.WriteLine(_path.Length);
for (uint i = 0; i < _path.Length; i++)
{
    Console.WriteLine(_path.X+","+_path.Y+","+_path.Z);
}
            
// Expected Output
2
1011,509,-70
1011,508,-70

// Real Output
2
1101,509,-3142
64515,47617,1011
Title: Re: How to use Script_GetPathArray (C#)
Post by: Orich on December 02, 2013, 12:13:19 PM
Tested and fixed.  Another stupid bug.

Download new version.


Add me to ICQ 691090807 ... Easier for fast fixes.  You are the only one testing C#, so better to talk in real time.
Title: Re: How to use Script_GetPathArray (C#)
Post by: rwo001 on December 02, 2013, 03:27:14 PM
Its work. Thanks..

Sorry i don't use icq..and i think my time zone is different from you..i'm in GMT+8...
if you have skype, please add me : live:raywongsk

 ;)