Raised This Month: $51 Target: $400
 12% 

Isis Mod


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
ichthys
Veteran Member
Join Date: Dec 2004
Location: []*[]
Old 05-31-2005 , 18:04   Isis Mod
Reply With Quote #1

Anyone had a look at this mod? I gave it a go a while ago but didn't quite get my head around it. Just been thinking that it might have some uses with eventscripts.
http://forums.alliedmods.net/showthread.php?t=37008
__________________
ichthys is offline
Cr3V3TT3
Senior Member
Join Date: Jul 2004
Location: V'dauban
Old 05-31-2005 , 22:28  
Reply With Quote #2

you can register command, so will be able to write your own library, isismod is cool

but use isismod to help eventscript is strnage what dont use isismod at all ^^
Cr3V3TT3 is offline
Send a message via MSN to Cr3V3TT3
ichthys
Veteran Member
Join Date: Dec 2004
Location: []*[]
Old 05-31-2005 , 22:47  
Reply With Quote #3

Its too hard. I've not used javascript at all!
__________________
ichthys is offline
Cr3V3TT3
Senior Member
Join Date: Jul 2004
Location: V'dauban
Old 05-31-2005 , 23:26  
Reply With Quote #4

i m trying a "array script"

three commands :

es_array_new <arrayname>
create a new array

es_array_get <arrayname> <index> <cvar>
set the <cvar> to the value of the <index> from <arrayname>

es_array_set <arrayname> <index> <value>
set the <index> value of <arrayname> to <value>


my first test dont work... ^^

EDIT :

Code:
var ArrayCount = 0;
var Arrays = new Array();
function ES_Array(name)
{
	this.name = name;
	this.v = new Array();
}
function GetArrayId(name)
{
	for(i in Arrays)
		if (Arrays[i].name==name)
			return i;
	return -1;
}
function es_array_new(cl, A)
{
	if (GetArrayId(A) == -1)
	{
		Arrays[ArrayCount] = new ES_Array(A);
		ArrayCount++;
	}
	else
		print("[EventScript array error] Array : "+A+" already exist\n");
}
function es_array_set(cl, A, B, C)
{
	var found = GetArrayId(A);
	if (found == -1) print("Array : "+A+" does not exist\n");
	Arrays[found].v[B] = C;
}
function es_array_get(cl, A, B, C)
{
	var found = GetArrayId(A);
	if (found == -1) print("Array : "+A+" does not exist\n");
	Env.Convar[C] = Arrays[found].v[B];
}
function onLoad ()
{
	Env.registerCommand("es_array_new",		es_array_new,		"register an isismod array");
	Env.registerCommand("es_array_set",		es_array_set,		"set an isismod array value");
	Env.registerCommand("es_array_get",		es_array_get,		"get an isismod array value");
}
Quote:
] es_array_new test
] es_array_set test 0 "new value"
] setinfo a ""
] es_array_get test 0 a
] a
"a" = "new value" ( def. "" )
- Custom user info value
:]

C u
Cr3V3TT3 is offline
Send a message via MSN to Cr3V3TT3
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 02:51.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode