wc3campaigns
WC3C Homepage - www.wc3c.netUser Control Panel (Requires Log-In)Engage in discussions with other users and join contests in the WC3C forums!Read one of our many tutorials, ranging in difficulty from beginner to advanced!Show off your artistic talents in the WC3C Gallery!Download quality models, textures, spells (vJASS/JASS), systems, and scripts!Download maps that have passed through our rigorous approval process!

Go Back   Wc3C.net > Warcraft III Modding > Developer's Corner > Warcraft Editing Tools
User Name
Password
Register Rules Get Hosted! Chat Pastebin FAQ and Rules Members List Calendar



Reply
 
Thread Tools Search this Thread
Old 02-27-2009, 06:56 PM   #1381
Vexorian
Free Software Terrorist
 
Vexorian's Avatar


Technical Director
 
Join Date: Apr 2003
Posts: 14,905

Submissions (37)

Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)

Hero Contest #3 - 2nd Place

Default

If I remember it is the factory that has the bug, and not jasshelper.

So maybe if you told me what the error actually says instead of just the line, it would help.
__________________
Zoom (requires log in)Wc3 map optimizer 5.0
Someone should fix .wav sound in this thing.
Zoom (requires log in)JassHelper 0.A.2.A
Turns your simple code into something that is complicated enough to work.
Faster != more useful
Vexorian is offline   Reply With Quote
Sponsored Links - Login to hide this ad!
Old 02-27-2009, 07:54 PM   #1382
Vexorian
Free Software Terrorist
 
Vexorian's Avatar


Technical Director
 
Join Date: Apr 2003
Posts: 14,905

Submissions (37)

Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)

Hero Contest #3 - 2nd Place

Default

Quote:
Originally Posted by C2H3NaO2
No it does not work without public, but if it extends something (struct or interface) it works without problems.
For now you can add a dummy private struct to fix it:

Collapse JASS:
struct st1
    public stub method asdf takes nothing returns nothing
    endmethod
endstruct

private struct dummy extends st1
endstruct
__________________
Zoom (requires log in)Wc3 map optimizer 5.0
Someone should fix .wav sound in this thing.
Zoom (requires log in)JassHelper 0.A.2.A
Turns your simple code into something that is complicated enough to work.
Faster != more useful
Vexorian is offline   Reply With Quote
Old 02-27-2009, 09:01 PM   #1383
gekko
User
 
gekko's Avatar
 
Join Date: Nov 2007
Posts: 129

Submissions (1)

gekko will become famous soon enough (33)gekko will become famous soon enough (33)

Default

Quote:
Originally Posted by gekko
is there a way to use getType() for arrays that are not extended from an interface? I have some structs extended from other structs and I would like to determine which child type a variable of the super struct type is.

Or can I just make a "dummy" superinterace with no content for the superstruct just to add this functionality. Or will I suffer other inconvenience (especially regarding performance) if I use a super interface?

Oh and I have found a bug:
You cannot give structs methods names that also a normal function already has . You get the error "1 is not a member of <THE_STRUCTTYPE>". I hope this is not intended, as there are many cases where I want a global function with the same name than a method of a struct, and it should be no problem to distinguish them, since they use different namespaces. I can also have globals and struct member variables with the same names, but no functions :(.

Next issue:

May it be that this "private keyword xxx" stuff totally malfunctions if used inside a library instead of a scope. Could you please fix this? I don't want to create a surrounding scope in my library just to add that private keyword stuff.
Because this adds a new problem: How to make a private init function in such a construct? I cannot make a scope init function, so i have to declare it as initializer for the library surrounding it. However, if I put a scope inside the library and make the init function private, the library header cannot see it as it is private to the scope, that is REALLY nasty and forces me to make many members public that i would need private in one library. It wastes all my encapsulation efforts :(.

Hey Vex. You seem to have skipped my post by accident(or ignored?). Could you please give some feedback?

Last edited by gekko : 02-27-2009 at 09:01 PM.
gekko is offline   Reply With Quote
Old 02-27-2009, 09:59 PM   #1384
Vexorian
Free Software Terrorist
 
Vexorian's Avatar


Technical Director
 
Join Date: Apr 2003
Posts: 14,905

Submissions (37)

Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)

Hero Contest #3 - 2nd Place

Default

Quote:
Or can I just make a "dummy" superinterace with no content
Sure, though getType should be trivial to make work in structs, I think there is just a check requiring interfaces for some odd reason.

Quote:
You cannot give structs methods names that also a normal function already has . You get the error "1 is not a member of <THE_STRUCTTYPE>". I hope this is not intended, as there are many cases where I want a global function with the same name than a method of a struct, and it should be no problem to distinguish them, since they use different namespaces. I can also have globals and struct member variables with the same names, but no functions :(.
This is related to scopes, if the function is in the same scope it will happen, that's a good thing because at least you have control of what goes in your scope so you can work around it, cause it seems unlikely this will get fixed too soon.

Quote:
May it be that this "private keyword xxx" stuff totally malfunctions if used inside a library instead of a scope. Could you please fix this?
For that sort of thing libraries and scopes are exactly the same thing, so I just don't think this is true, you'll have to give actual examples.


Edit: I just fixed that bug with stub methods on a final struct causing PJass errors and also made getType() callable on any struct instance, if anyone has a quick bug report to make, better do it in the next few hours before I make the new release...
__________________
Zoom (requires log in)Wc3 map optimizer 5.0
Someone should fix .wav sound in this thing.
Zoom (requires log in)JassHelper 0.A.2.A
Turns your simple code into something that is complicated enough to work.
Faster != more useful
Vexorian is offline   Reply With Quote
Old 02-28-2009, 04:20 AM   #1385
Vexorian
Free Software Terrorist
 
Vexorian's Avatar


Technical Director
 
Join Date: Apr 2003
Posts: 14,905

Submissions (37)

Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)

Hero Contest #3 - 2nd Place

Default

all right, F.4
__________________
Zoom (requires log in)Wc3 map optimizer 5.0
Someone should fix .wav sound in this thing.
Zoom (requires log in)JassHelper 0.A.2.A
Turns your simple code into something that is complicated enough to work.
Faster != more useful
Vexorian is offline   Reply With Quote
Old 02-28-2009, 09:21 AM   #1386
gekko
User
 
gekko's Avatar
 
Join Date: Nov 2007
Posts: 129

Submissions (1)

gekko will become famous soon enough (33)gekko will become famous soon enough (33)

Default

Quote:
Originally Posted by Vexorian
all right, F.4
The getType() method can be called on any struct instance (not just interface variables)
Yay, big thanks :).
I will find a codeexample for my private keyword issue.

concerning function/method with same name:

I am totally sure that the function and the struct method were in different scopes. They were in different libraries, to be precise. But I cannot reconstruct that bug at the moment it works, strange.

Next issue:
I need something that is private but can be shared between two libraries. I really don't want to merge them to one, because they re really big and do different things and I like to have them in two different triggers, but they share some private content. How could this be done?

Last edited by gekko : 02-28-2009 at 09:26 AM.
gekko is offline   Reply With Quote
Old 02-28-2009, 10:02 AM   #1387
ShadowDestroyer
User
 
ShadowDestroyer's Avatar
 
Join Date: Jan 2006
Posts: 375

ShadowDestroyer is on a distinguished road (15)

Send a message via AIM to ShadowDestroyer
Default

I don't think it is spell factory...

The error is simply "Syntax Error", with no other information.
__________________
The Shadow of Destruction

clanmord.net
Try Tropical Tag, Militia Rebellion, Capture the Flag WSG, and Footmen Frenzy XV!
ShadowDestroyer is offline   Reply With Quote
Old 02-28-2009, 10:04 PM   #1388
Av3n
Roar!
 
Av3n's Avatar


Project Leader: TBR
Project Member: PoC
 
Join Date: May 2006
Posts: 1,853

Submissions (7)

Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)

Hero #4 extra-official winner2008 Spell olympics - Fire - BronzeHero Contest #3 - 3rd Place

Default

Ok Vexorian I think the new JASSHelper cannot handle more than 23188 lines anymore, I get this error right before "JASSHelper - Structs Writing" finishes:

Access violation at address 00480E08 in module 'jasshelper.exe'. Read of address 00000016.

This is with your latest one F.4. Or it just might be my Vista failing at life, since it works on smaller ones.

-Av3n
__________________

Thanks to FatherTime for the sig
.:
Current ProjectsSubmissions
Power of CorruptionMy Terrain
The Black RoadMy Resources
Strikeforce
Twitter
Av3n is offline   Reply With Quote
Old 02-28-2009, 10:42 PM   #1389
Vexorian
Free Software Terrorist
 
Vexorian's Avatar


Technical Director
 
Join Date: Apr 2003
Posts: 14,905

Submissions (37)

Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)

Hero Contest #3 - 2nd Place

Default

I doubt it is related to large files.

the bad news is that you'll probably have to disable triggers one by one until you find what's causing thing.

edit: ...or you can send me your inputwar3map.j
__________________
Zoom (requires log in)Wc3 map optimizer 5.0
Someone should fix .wav sound in this thing.
Zoom (requires log in)JassHelper 0.A.2.A
Turns your simple code into something that is complicated enough to work.
Faster != more useful
Vexorian is offline   Reply With Quote
Old 03-01-2009, 02:12 AM   #1390
ShadowDestroyer
User
 
ShadowDestroyer's Avatar
 
Join Date: Jan 2006
Posts: 375

ShadowDestroyer is on a distinguished road (15)

Send a message via AIM to ShadowDestroyer
Default

Hey Vex,

The Spell Factory returns:
function SlashTemplate_DoSpell takes player ow, unit t, integer s, integer l returns nothing

and the only information it gives is "Syntax Error".

Would you mind helping me out?
__________________
The Shadow of Destruction

clanmord.net
Try Tropical Tag, Militia Rebellion, Capture the Flag WSG, and Footmen Frenzy XV!
ShadowDestroyer is offline   Reply With Quote
Old 03-01-2009, 02:27 AM   #1391
TriggerHappy
 
Join Date: Feb 2008
Posts: 404

Submissions (2)

TriggerHappy will become famous soon enough (43)TriggerHappy will become famous soon enough (43)

Default

Whats the line above/under that line.
TriggerHappy is offline   Reply With Quote
Old 03-01-2009, 03:16 AM   #1392
Av3n
Roar!
 
Av3n's Avatar


Project Leader: TBR
Project Member: PoC
 
Join Date: May 2006
Posts: 1,853

Submissions (7)

Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)

Hero #4 extra-official winner2008 Spell olympics - Fire - BronzeHero Contest #3 - 3rd Place

Default

a.k.a, post the whole damn code, people cannot solve problems with with jsut one line of code, even if it is the creator of the system.

I'll PM the inputwar3map.j

-Av3n
__________________

Thanks to FatherTime for the sig
.:
Current ProjectsSubmissions
Power of CorruptionMy Terrain
The Black RoadMy Resources
Strikeforce
Twitter
Av3n is offline   Reply With Quote
Old 03-01-2009, 11:41 AM   #1393
Troll-Brain
User
 
Join Date: Oct 2006
Posts: 1,490

Submissions (1)

Troll-Brain has a spectacular aura about (134)

Default

A suggestion.
Could you create an other thing :

Block <optional name> / endblock : Just a code block, we can't use private or public, and we can use the same name several times if we want.

What's the point of that ?
Hide/unhide hudge block codes to keep the readability of the code, an alternative of nested scopes.
Troll-Brain is offline   Reply With Quote
Old 03-01-2009, 01:08 PM   #1394
Vexorian
Free Software Terrorist
 
Vexorian's Avatar


Technical Director
 
Join Date: Apr 2003
Posts: 14,905

Submissions (37)

Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)Vexorian has a reputation beyond repute (1060)

Hero Contest #3 - 2nd Place

Default

Hiding? Is that editor-related ? Reminds me of C#'s regions. Hmnn.
__________________
Zoom (requires log in)Wc3 map optimizer 5.0
Someone should fix .wav sound in this thing.
Zoom (requires log in)JassHelper 0.A.2.A
Turns your simple code into something that is complicated enough to work.
Faster != more useful
Vexorian is offline   Reply With Quote
Old 03-01-2009, 01:47 PM   #1395
Troll-Brain
User
 
Join Date: Oct 2006
Posts: 1,490

Submissions (1)

Troll-Brain has a spectacular aura about (134)

Default

I mean minimize / show the block like that :
Expand Block minimized:
Collapse Block not minimized:
// code
Ofc, TESH must also be edited as well, but it would be very easy and fast to add this.
Troll-Brain is offline   Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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

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


All times are GMT. The time now is 11:30 PM.


Donate

Affiliates
The Hubb http://bylur.com - Warcraft, StarCraft, Diablo and DotA Blog & Forums The JASS Vault Clan WEnW Campaign Creations Clan CBS GamesModding Flixreel Videos

Powered by vBulletin (Copyright ©2000 - 2014, Jelsoft Enterprises Ltd).
Hosted by www.OICcam.com
IT Support and Services provided by Executive IT Services