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

Showing results 1 to 22 of 22
Search took 0.00 seconds.
Search: Posts Made By: joaquimandrade
Forum: Code Snippets/Tutorials 04-22-2009, 13:39
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

xPaw, tasks are not suitable for profiling it seems.

Edit: Of course they aren't. Profiling tasks is like profiling forwards. They are called from the module so you just can't do it.



date:...
Forum: Code Snippets/Tutorials 04-20-2009, 17:22
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

It doesn't have more code. You are forgetting that fm_create_entity has more calls inside it.

Calling functions inside modules is less expensive than plugins calling module provided functions.
Forum: Code Snippets/Tutorials 04-20-2009, 14:31
Replies: 121
Views: 159,206
Posted By joaquimandrade
Forum: Code Snippets/Tutorials 04-18-2009, 15:35
Replies: 121
Views: 159,206
Posted By joaquimandrade
Forum: Code Snippets/Tutorials 04-18-2009, 14:13
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

I can't understand what you said
Forum: Code Snippets/Tutorials 04-18-2009, 12:39
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

In Pawn not. There's only a type of data called cell. The "bool:" , "Float:" , etc, are only tags to help the user operating over data.

An easy way to prove that is that every native provided to...
Forum: Code Snippets/Tutorials 04-18-2009, 04:20
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

The best way would be to compare each function and use which was faster. As a rule you can chose the way less natives are called.

#define fm_create_entity(%1) engfunc(EngFunc_CreateNamedEntity,...
Forum: Code Snippets/Tutorials 03-30-2009, 11:44
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

Anyway, the point of all this story is that the true is fair from "Porting everything to fakemeta is optimizing".
Forum: Code Snippets/Tutorials 03-30-2009, 11:12
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

Can you talk to a developer to tell us he's final opinion on that matter?
Forum: Code Snippets/Tutorials 03-30-2009, 11:07
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

So you are talking about the time that it takes since the module searches for the hooks that it have to call and the actual call.
I guess that that time is outside of the scope of the profile...
Forum: Code Snippets/Tutorials 03-30-2009, 10:52
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

What "a forward being faster than other" means?
Forum: Code Snippets/Tutorials 03-30-2009, 10:34
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

I have two questions:

How can increment a variable inside a forward be less or more expensive depending on which forward?

What is the point of profiling forwards?

Anyway, i've made more...
Forum: Code Snippets/Tutorials 03-29-2009, 17:40
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

I know what it is but also never needed to check if "equals 2".



I guess that there isn't any difference.
Forum: Code Snippets/Tutorials 03-29-2009, 17:20
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

Ok. So the comparison is not fair.
A question: is it normal needing the "return 2" case?
Forum: Code Snippets/Tutorials 03-29-2009, 16:27
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

More. (I'm assuming that pev_valid(id) is equivalent to is_valid_ent(id)). If they aren't, the results are invalid.
Forum: Code Snippets/Tutorials 03-29-2009, 16:04
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

No. He just said that more tests should be made. Here they are and fakemeta is never faster.
Forum: Code Snippets/Tutorials 03-29-2009, 15:59
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

He's right about what? Using fakemeta is never faster, even not being engine always clearly faster.

Basically:

All this years everybody (Except Hawk) thought that fakemeta way was faster....
Forum: Code Snippets/Tutorials 03-29-2009, 15:54
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

About set_pev/entity_set the results say that it is basically the same thing.

(The same for pev/entity_get)
Forum: Code Snippets/Tutorials 03-29-2009, 15:36
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

About:



My guess is that it is the same thing (Or probably engine better since there's no need to check the data type (i guess)). Will profile later.
Forum: Code Snippets/Tutorials 03-29-2009, 11:24
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

The thing is: despite the fact that his code make things better it also does things wrong. It is re-setting models on spawn so, in a 32 slots full server, when a round begins it is re-setting 32...
Forum: Code Snippets/Tutorials 03-29-2009, 11:04
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

But it hooks spawn and it uses task. As i said in there is better. I never need to mess with models but, if someday i do, i will surely modify his code.

Basically:

It hooks spawns. That's an...
Forum: Code Snippets/Tutorials 03-29-2009, 08:54
Replies: 121
Views: 159,206
Posted By joaquimandrade
Re: [TUT] Modules and efficient scripting

FM, absolutely. But, you can improve Mercylez code. Look at this:

http://forums.alliedmods.net/showpost.php?p=769807&postcount=40
http://forums.alliedmods.net/showpost.php?p=773460&postcount=44
...
Showing results 1 to 22 of 22

 
Forum Jump

All times are GMT -4. The time now is 20:26.


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