UGX-Mods

UGX-Mods => Announcements => Topic started by: Delta on June 13, 2014, 08:20:50 pm

Title: UGX Scripting Reference [ALPHA] released
Post by: Delta on June 13, 2014, 08:20:50 pm
Today we are finally ready to release an alpha build of the UGX Scripting Reference to the public!

Visit the UGX Scripting Reference (http://ugx-mods.com/script)
http://ugx-mods.com/script (http://ugx-mods.com/script)

(https://www.ugx-mods.com/forum/proxy.php?request=http%3A%2F%2Fi.imgur.com%2F2yKie6c.png&hash=e55a9864dd9d31c05cdc1b593c9e8e7ac133babe)

What is the UGX Scripting Reference?

If you're not a scripter then this probably won't interest you. For those of you who are scripters the UGX Scripting Reference is unlike any scripting reference you've ever used before. The UGX Scripting Reference has tons of cool features and functions that have never been seen before.

Features


Alpha? What's left to do?

Everything needs to be tested. Obviously there are still bugs we have not discovered and releasing a public alpha for everyone to test is the fastest way to find them. If you find a bug with the UGX Scripting Reference, please reply to this topic describing what you were trying to do when the bug occurred and what the bug is.

Lots of functions are untested or missing and we need your feedback on this. There are also certain functions marked with tags that indicate their functionality is unknown, or that they might not work at all. We have tags to indicate the status of a function, such as if a function exists but does not work or has not been verified as working. If you find a function which should be marked with these tags please let us know in this topic.

We want your opinion. Do you have any suggestions for improving the UGX Scripting Reference? Features that should be added, changed, or removed? Please let us know in this topic.
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: Lukkie1998 on June 14, 2014, 01:19:07 pm
looks nice guys. Keep up the good work!!

Lukkie1998
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: Dust on June 14, 2014, 01:49:10 pm
Nice! Since I am starting to learn more about scripting, this should help
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: Delta on June 14, 2014, 03:53:09 pm
btw. there is a known issue that the search function only works in Firefox.
As soon as I get some more time I try to find a solution.
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: DeletedUser on June 14, 2014, 04:09:39 pm
Sorry Delta, but the sample link is broken too.
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: daedra descent on June 14, 2014, 05:18:43 pm
Some of the untested functions don't look right. They say that the function arguments strings, but it looks like they use entities. Is this just because they aren't tested?

Also, how would you like us to tell you about what functions have been tested? On this thread? How specific do you want it to be?
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: treminaor on June 14, 2014, 06:25:57 pm
Some of the untested functions don't look right. They say that the function arguments strings, but it looks like they use entities. Is this just because they aren't tested?
Give us some examples of the functions you're looking at.
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: MakeCents on June 14, 2014, 11:55:53 pm
This is great. Would have been way more useful 4 months ago, but this is great. This seems to be much easier to navigate than other resources I have found, and the colors and layout work well. Thanks for this.
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: treminaor on June 15, 2014, 12:35:16 am
This is great. Would have been way more useful 4 months ago, but this is great. This seems to be much easier to navigate than other resources I have found, and the colors and layout work well. Thanks for this.
Probably could have had it done 4 months ago but we have so many active projects right now Delta and I kinda just jump around until one gets really close to being finished like this.
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: MakeCents on June 15, 2014, 12:47:19 am
Probably could have had it done 4 months ago but we have so many active projects right now Delta and I kinda just jump around until one gets really close to being finished like this.

Lol, I know how that is. It will still be super useful for me, and I'm sure many, many others. Good stuff.  :D
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: Delta on June 15, 2014, 06:05:29 am
=D

I think going over each function would make this thread to a  200 page long issue list.
Many functions where just added automatically with my tiny application.

Apperently there was no real comment standard so some functions are a bit messed up.
I'll try to reduce the mess a bit.

I want to enable for any scripter the edit mode as soon as possible. Therefore scripters can correct any issues.
( but this requires some changes first )

I think the best way to report issues would be by creating a list in a text document and then sent it to me via skype or just as a direct download.

The mentioned array issue might get fixed very easily. ;)
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: daedra descent on June 15, 2014, 07:02:03 am
I want to enable for any scripter the edit mode as soon as possible. Therefore scripters can correct any issues.
( but this requires some changes first )

So only Community Scripters can edit them?
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: treminaor on June 15, 2014, 07:11:05 am
So only Community Scripters can edit them?
Only people who really know what they are doing should/will be able to edit them. The last thing we need are people who dont know with 100% certainty on the datatypes or whatever else they are editing - that just makes a mess and we end up with false information in the reference. So idk if just giving it to the CS group is a good idea or if we should choose specific people yet.
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: GrantDaddy007 on June 15, 2014, 02:16:35 pm
Awesome!
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: daedra descent on June 16, 2014, 06:29:36 am
I didn't test it, just going off of what the function has in the utility scripts.

Function:

Code Snippet
Plaintext
getAIarrayTouchingVolume( sTeamName, sVolumeName, eVolume )

Description: Returns an array of AI touching a trigger.

Function arguments:
sTeamName: Required(string). The "Team" to get an array of. Options include "Allies", "Axis", and "all".
sVolumeName: Required(string). The targetname of the entity to check.
evolume: Optional(entity). The entity to get. Overrides the sVolumeName argument string.



Title: Re: UGX Scripting Reference [ALPHA] released
Post by: treminaor on June 16, 2014, 06:46:15 am
I didn't test it, just going off of what the function has in the utility scripts.

Function:

Code Snippet
Plaintext
getAIarrayTouchingVolume( sTeamName, sVolumeName, eVolume )

Description: Returns an array of AI touching a trigger.

Function arguments:
sTeamName: Required(string). The "Team" to get an array of. Options include "Allies", "Axis", and "all".
sVolumeName: Required(string). The targetname of the entity to check.
evolume: Optional(entity). The entity to get. Overrides the sVolumeName argument string.
I'm pretty sure the reason those functions have no description yet is because Delta is still working on parsing them out of the utility scripts. I would focus on the functions not from [SP/MP] Utility Functions at this time.
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: Delta on June 16, 2014, 07:25:33 am
No. Parsing is done. - And with no information to this function I can't magically generate all information.
There were some mistakes made in my parsing ( I could have read the actual variable name which often reveals the datatype itself )

As merging this into the DB is time consuming I try to write this in PHP, but enough technical talk.

Obviously any function which has the giant "automatically box" is not correct. - Utility functions are the most worst, as some are just helper functions for other functions and most of them are undocumented. ( and therefore also in a group like unknown, undefined, a classic is _anim )

There are also some chrome issues ( and as usual IE ) which I will fix in this week - whenever I have a couple of hours

Be patient ;) - it's finally out after a long time beeing an inactive project and current state is surprisingly good^^
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: treminaor on June 16, 2014, 07:30:25 am
Oh wait was Daedra posting his own description of the function? I misunderstood, thought he was copy/pasting from one of the doc comments above the functions in the utility file.

Yeah if the information isn't there to parse out in the first place then unfortunately the information will have to be filled in manually by someone. I would prefer if you tested the function before writing the usage because for all we know the function may not even work (and we can label it as such) or be worth documenting.
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: daedra descent on June 16, 2014, 07:27:47 pm
Oh wait was Daedra posting his own description of the function? I misunderstood, thought he was copy/pasting from one of the doc comments above the functions in the utility file.

Yeah if the information isn't there to parse out in the first place then unfortunately the information will have to be filled in manually by someone. I would prefer if you tested the function before writing the usage because for all we know the function may not even work (and we can label it as such) or be worth documenting.

Just tested using an SP map. Works perfectly.

Code(s) used:
Spoiler: click to open...

Test 1: No eVolume override

Code Snippet
Plaintext
volume_check()
{
ai = undefined;
override_volume = getent("test_volume", "targetname");
while(1)
{
ai = getAIarrayTouchingVolume("allies", "test_volume");

for( i = 0; i < ai.size; i++ )
{
ai[i] dodamage(999999, ai[i].origin);
iprintln("AI has been killed");
}
wait(1);
}
}

Test 2: with eVolume override

Code Snippet
Plaintext
volume_check()
{
ai = undefined;
override_volume = getent("test_volume", "targetname");
while(1)
{
ai = getAIarrayTouchingVolume("allies", "test_volume", override_volume);

for( i = 0; i < ai.size; i++ )
{
ai[i] dodamage(999999, ai[i].origin);
iprintln("AI has been killed");
}
wait(1);
}
}


In-game result:

Spoiler: click to open...
(https://www.ugx-mods.com/forum/proxy.php?request=http%3A%2F%2Fi.gyazo.com%2Fadc0c1a17e357db86774b98c1a00ff78.png&hash=6a932eb0022a83839eeccdc59f422ee13500463a)
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: treminaor on June 16, 2014, 08:05:22 pm
Added (http://ugx-mods.com/script/#utility.unknown.getAIarrayTouchingVolume)
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: Delta on June 19, 2014, 09:27:24 pm
Yay, first update is out and running. Chrome can actually enjoy the Script Reference as well.

Code Snippet
Plaintext
fixed filter button misplacement in chrome
fixed search - it actually works in chrome now

these two fixes will most likey be noticeable in other browsers as well ]=D

fixed "Copy To Clipboard" icon won’t work with a function which hasn’t been visted yet.
will display a refresh icon + wait curser while it’s getting the data [fast and fancy fix^^]

fixed tooltip will mirror to the top and is gone when window height is too low.

fixed filters. Work in chrome now.

tweaking behavior of the search textfield

About content issues ( wrong datatype, description, ... )

As mentioned already, I'll give scripters with a great knowledge access to the dev tool, to update functions in realtime. ( as we UGX dev do )
As this requires the Usermenu ( and most likeley the chat as well ) it will take a bit to grant access to this.

In the meantime, if you notice something dramatically int the core category then please report so we can fix it asap.
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: GerardS0406 on July 31, 2014, 04:57:18 pm
Can you plz tell the non-donators more about what ugx is doing right now because we've been waiting for a while!
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: Delta on July 31, 2014, 05:14:34 pm
Can you plz tell the non-donators more about what ugx is doing right now because we've been waiting for a while!

Well we are busy ;)

The rest of the team is working on UGX Mod v1.1 while I work on other things.
( Donors will get this info first soon enough + after some days everyone else )

There is a new Devlog ( 17th July ) which should be available to public very soon as well
( But everyone is mainly busy and we will share information as soon as it makes sense )

And there is also a small hint on twitter ( 5 days ago ) ;)
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: GerardS0406 on July 31, 2014, 06:06:47 pm
k thank u!  ;)
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: AoKMiKeY on August 06, 2014, 09:21:45 pm
Hello all, I have never posted on this site before but as a very experience call of duty 5 coder i have decided to test some of the unconfirmed functions in the script reference...

isString( string );

i can confirm this works for call of duty 5 zombies and single player. I am not able to test in MP

code used to test the function
Code Snippet
Plaintext
testString(string, notstring)
{

if( isString(string) )
self iPrintln("true "+string);
else
self iPrintln("false "+string);

if( isString(notstring) )
self iPrintln("true "+notstring);
else
self iPrintln("false "+notstring);
}

when used:
testString( "hello", 10 );

result
"true hello"
"false 10"


From AoKMiKeY :)
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: treminaor on August 06, 2014, 10:46:50 pm
isString( string );
i can confirm this works for call of duty 5 zombies and single player. I am not able to test in MP
Thanks, I have approved the function now.
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: johndoe on August 07, 2014, 12:16:28 am
(https://www.ugx-mods.com/forum/proxy.php?request=http%3A%2F%2Fi.gyazo.com%2Fced2612d9772937e9fa72cd85e3fa135.gif&hash=9ce2f08b85073a54e955812a8044296de3c12913)

I just realized it lists the functions two times.
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: treminaor on August 07, 2014, 12:19:39 am
(http://i.gyazo.com/ced2612d9772937e9fa72cd85e3fa135.gif)

I just realized it lists the functions two times.
Yeah Delta merged two different lists of functions a couple weeks ago and it created some duplicates. He's working on fixing it but right now we are more focused on the new Map Manager update that's in the works.
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: AoKMiKeY on August 16, 2014, 12:29:55 am
Hello, I have another on for you.

I am a writer on the wiki site http://wiki.modsrepository.com (http://wiki.modsrepository.com) and i have just added this one onto the site after running into it. It works on SP and Zombies also MP.

http://wiki.modsrepository.com/index.php?title=Call_of_Duty_4:_Scripting_Reference_-_Mathl::Abs (http://wiki.modsrepository.com/index.php?title=Call_of_Duty_4:_Scripting_Reference_-_Mathl::Abs)

Sorry, Cant be asked to write it all again. Please reference the site.

Thank you,
                AoKMiKeY
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: treminaor on August 16, 2014, 01:27:59 am
Hello, I have another on for you.
Replied to your PM.
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: AoKMiKeY on August 17, 2014, 05:35:16 pm
Awesome. I have replied :P
Title: Re: UGX Scripting Reference [ALPHA] released
Post by: n123q45 on September 06, 2014, 09:09:59 pm
the updateBar function found in maps\_hud_util.gsc