(Keeps Hive Alive)
Go Back   The Hive Workshop - A Warcraft III Modding Site > Warcraft III Resources > JASS Functions

JASS Functions Approved JASS functions will be located here.
Remember to submit your own resources to the submission forum.

Reply
 
LinkBack Thread Tools Display Modes
Old 06-16-2007, 05:07 PM   #16 (permalink)
Overall Site Manager
 
Wolverabid's Avatar

 
Join Date: Oct 2006
Posts: 8,793

Wolverabid has much of which to be proud (1207)Wolverabid has much of which to be proud (1207)

Respected User: This user has been given the respected user award. User of the Year: 2007 

Bug [off-topic]

Why the heck even > I < can't rename the thread from "H2i" to "H2I" only the webmaster can say.

I (unsucessfully) tried to edit both the thread itself and the original post.

I have another card hidden up my sleeve: I'll play that one.

[EDIT] <expletive deleted>
Wolverabid is offline   Reply With Quote
Old 06-16-2007, 05:08 PM   #17 (permalink)
Owner, Developer & Technical Director
 
Ralle's Avatar

WoW! StarCraft II
 
Join Date: Oct 2004
Posts: 6,641

Ralle has disabled reputation (1460)Ralle has disabled reputation (1460)Ralle has disabled reputation (1460)Ralle has disabled reputation (1460)Ralle has disabled reputation (1460)Ralle has disabled reputation (1460)


yes I tried that too.. Excellent vBulletin!
__________________
Info:
Ralle'sSigna-ture
Todo ListPM MeNews
Progress:
New Section
||||||||||
Ralle is offline   Reply With Quote
Old 06-16-2007, 10:22 PM   #18 (permalink)
Spell and Map Moderator
 
Dr Super Good's Avatar

The Helpful Personage
 
Join Date: Jan 2005
Posts: 4,375

Dr Super Good is a name known to all (629)


Some kind of auto correction function. I renamed this to "H 2 I" Untill another way is discovered to rename this to its propper name "H2I". Maybe lookover the Vbuiltin auto correction options, its some kind of basic correction that happens when you rename the tital.
Dr Super Good is offline   Reply With Quote
Old 06-16-2007, 11:08 PM   #19 (permalink)

iRawr
 
Join Date: Dec 2005
Posts: 8,882

PurplePoot is a name known to all (710)PurplePoot is a name known to all (710)PurplePoot is a name known to all (710)PurplePoot is a name known to all (710)

Respected User: This user has been given the respected user award. Map Development Mini-Contest #1 Winner: Stand of the Elements 

It's probably anti- OMG IM SO PISSED CANT GET THIS TO WORK PLZ HELP LOLOL (caps spamming), which is good in a few ways, I guess, but does have its disadvantage.

There's probably a way to disable it. Who knows...
PurplePoot is offline   Reply With Quote
Old 06-17-2007, 09:29 AM   #20 (permalink)
 
paskovich's Avatar

I am ghost
 
Join Date: Jul 2005
Posts: 942

paskovich has a spectacular aura about (124)paskovich has a spectacular aura about (124)paskovich has a spectacular aura about (124)paskovich has a spectacular aura about (124)


Name it "Typecasting - Handle to integer"? :D
H2I is not a descriptive name at all...
__________________
Jimmy Eat World - Let It Happen
"I'm the evil one who said.
Gonna let everything just happen
like my chest, my ears are proud
The collision is such an ugly sound."
Vote for the Hive without mercy!
paskovich is offline   Reply With Quote
Old 06-18-2007, 12:59 PM   #21 (permalink)

iRawr
 
Join Date: Dec 2005
Posts: 8,882

PurplePoot is a name known to all (710)PurplePoot is a name known to all (710)PurplePoot is a name known to all (710)PurplePoot is a name known to all (710)

Respected User: This user has been given the respected user award. Map Development Mini-Contest #1 Winner: Stand of the Elements 

So, are we planning on reaching any sort of conclusion on this?

Admins: will we make an exception for H2I, and mention SuperIKI in the credits (who PitzerMike said was the first person to use H2I, and thus I assume he was the one that made it), or shall we stick 100% to the rule that Griffen pointed out?
PurplePoot is offline   Reply With Quote
Old 07-13-2007, 03:20 PM   #22 (permalink)
Owner, Developer & Technical Director
 
Ralle's Avatar

WoW! StarCraft II
 
Join Date: Oct 2004
Posts: 6,641

Ralle has disabled reputation (1460)Ralle has disabled reputation (1460)Ralle has disabled reputation (1460)Ralle has disabled reputation (1460)Ralle has disabled reputation (1460)Ralle has disabled reputation (1460)


Give credit to the guy and I will approve it :)
__________________
Info:
Ralle'sSigna-ture
Todo ListPM MeNews
Progress:
New Section
||||||||||
Ralle is offline   Reply With Quote
Old 10-01-2007, 06:24 AM   #23 (permalink)
 
PandaMine's Avatar

User
 
Join Date: Sep 2007
Posts: 63

PandaMine has little to show at this moment (24)PandaMine has little to show at this moment (24)PandaMine has little to show at this moment (24)


damagetype, attacktype, weapontype and playerstate

The above handles are actually constant integers, when you use H2I on a certain damage type for example it will always return the same value for that damage type i.e. DAMAGE_TYPE_MAGIC is 14 etc. You should probably mention that is the reason why you can get problems with it, although the indexes for the pointer type handles start at 1048665
PandaMine is offline   Reply With Quote
Old 03-19-2008, 01:16 AM   #24 (permalink)
 
Herman's Avatar

Need to buy myself a comp
 
Join Date: Aug 2007
Posts: 1,049

Herman has little to show at this moment (33)Herman has little to show at this moment (33)Herman has little to show at this moment (33)Herman has little to show at this moment (33)


Hold on a sec

So, this storage system kinda gives any handle a custom value???

I suppose this would be the very efficient JASS way of using an array (similar function could be done using GUI arrays)

How does it work??
couldn't understand a few things...
parser = compiler?
satiates = I have no idea!?!?!?
__________________
Half of the worlds population is below average intelligence
Herman is offline   Reply With Quote
Old 03-20-2008, 02:34 PM   #25 (permalink)
 
Silvenon's Avatar

BBoy Silv
 
Join Date: Nov 2006
Posts: 867

Silvenon is on a distinguished road (81)Silvenon is on a distinguished road (81)


Well, not exactly, this allows you to store stuff in a game cache, which is used for transferring data between maps (campaigns for example). This way you can transfer data from one function to another through a certain handle that is common to both functions.

Due to the laginess of game cache, it is really bad to use plain Handle Vars system (made by KaTTaNa - wc3jass.com), so people made few improvement systems. Vexorian's JNGP allows the best and the fastest way to do that.

Note that not all handles can transfer data like that, there are handles that are not-exactly-handles, such as the ones that Diablo pointed out.

But you can always use global arrays...... :)
Silvenon is offline   Reply With Quote
Old 03-20-2008, 05:37 PM   #26 (permalink)
 
Herman's Avatar

Need to buy myself a comp
 
Join Date: Aug 2007
Posts: 1,049

Herman has little to show at this moment (33)Herman has little to show at this moment (33)Herman has little to show at this moment (33)Herman has little to show at this moment (33)


Heh

Yeah I was making another quadratic spell using JASS, and I noticed it would be 10000x more efficient using the LocalVars() stuffs, if I wanted to use global arrays I woulda just done it in GUI x)

I'm gonna make another thread with that code in it, and questions on how to make it MUI, and how to use the LocalVars() appropriately (and a few others about damage_area)
__________________
Half of the worlds population is below average intelligence
Herman is offline   Reply With Quote
Old 03-20-2008, 10:41 PM   #27 (permalink)
 
HINDYhat's Avatar

Banned
 
Join Date: Apr 2007
Posts: 1,034

HINDYhat is a glorious beacon of light (553)HINDYhat is a glorious beacon of light (553)HINDYhat is a glorious beacon of light (553)HINDYhat is a glorious beacon of light (553)HINDYhat is a glorious beacon of light (553)HINDYhat is a glorious beacon of light (553)

Super Donor: This user has donated at least $100 to The Hive. 

Globals are actually a lot faster to work with than Local Handle Vars or CS_Cache.
__________________
HINDYhat is offline   Reply With Quote
Old 03-21-2008, 12:45 AM   #28 (permalink)
 
Herman's Avatar

Need to buy myself a comp
 
Join Date: Aug 2007
Posts: 1,049

Herman has little to show at this moment (33)Herman has little to show at this moment (33)Herman has little to show at this moment (33)Herman has little to show at this moment (33)


:O

:O
:O
:O

Then how does vJass get it's legendary speed that I keep hearing about over and over again?

//====================================

Question about globals vs. local handle vars
I made a quadratic arc type of function, and I was wondering if I used global arrays, and just one integer attached to the timer to reference all of the information from the globals, would that be faster than to use all of the information attached to the timer?

//====================================
I apologize for the original question, thought satiates was a typo

Code:
Anyway, the Jass parser only checks that the last return value satisfies the return type
makes much more sense to me

Ah yes!, I finally get it!!

The function returns an integer, when it already returned a handle, giving the handle a reference (I think?)

Also, do you need to nullify integers, reals, booleans, etc. if they are attached to handles using the vars system?
__________________
Half of the worlds population is below average intelligence

Last edited by Herman; 03-21-2008 at 10:03 PM.
Herman is offline   Reply With Quote
Old 03-21-2008, 11:25 PM   #29 (permalink)
 
Herman's Avatar

Need to buy myself a comp
 
Join Date: Aug 2007
Posts: 1,049

Herman has little to show at this moment (33)Herman has little to show at this moment (33)Herman has little to show at this moment (33)Herman has little to show at this moment (33)


Sorry for double-post

Figured you guys couldn't see that I added more questions to the original

I'm starting to understand how the bug exploit works, but how could I connect an integer to a handle, rather than a handle stored as an integer?
__________________
Half of the worlds population is below average intelligence
Herman is offline   Reply With Quote
Old 03-21-2008, 11:35 PM   #30 (permalink)
 
PurgeandFire111's Avatar

User Title
 
Join Date: Nov 2006
Posts: 1,060

PurgeandFire111 is a jewel in the rough (152)


Null non-handles and it is optional to null permanent stuffs. But you should just in case.
__________________
Vote For The Hive Workshop!
Funny but the TRUTH! :
Quote:
Originally Posted by Sopho
Unprotecting maps is not right its like crime and YOU GO MAKE YOUR OWN MAP AND BE HAPPY! Don't be gay n00b!

1. You can if it is yours but you should not if it is not. It is like stealing information and using it as if it is your own. It si gay stuff and people who unprotect maps are gay themselves.
PurgeandFire111 is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

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
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem with Handle Var Marcelo Hossomi World Editor Help Zone 9 05-15-2007 11:49 PM
moderators who handle how they like to do it? dhk_undead_lord Off-Topic 16 01-13-2007 12:23 PM
[JASS] get/store integer with integer index per unit Lord Raszul Requests 0 12-17-2005 06:47 PM
[JASS] Item Handle Dr.Nitro Triggers & Scripts 2 12-03-2005 12:52 AM
[JASS] explain handle? wikidme