wc3edit.net

United Warcraft 3 map hacking!
It is currently April 24th, 2024, 7:12 am

All times are UTC




Post new topic Reply to topic  [ 15 posts ]  Go to page Previous  1, 2
Author Message
 Post subject: Re: Activation code
PostPosted: October 26th, 2007, 6:17 pm 
Offline
Forum Staff
User avatar

Joined: June 3rd, 2007, 8:03 pm
Posts: 1008
You tricked me xantan I thought you'd actually talked to him, so I cancelled my post. ;/

Anyway just change:
Code:
if SubString(s,0,5)=="-gold" then
call SetPlayerState(p,PLAYER_STATE_RESOURCE_GOLD,GetPlayerState(p,PLAYER_STATE_RESOURCE_GOLD )+S2I(SubString(s,6,13)))
elseif SubString(s,0,7)=="-lumber" then
call SetPlayerState(p,PLAYER_STATE_RESOURCE_LUMBER,GetPlayerState(p,PLAYER_STATE_RESOURCE_LUMBER )+S2I(SubString(s,8,15)))
to:
Code:
if SubString(s,0,5)=="-gold" then
call SetPlayerState(p,PLAYER_STATE_RESOURCE_GOLD,GetPlayerState(p,PLAYER_STATE_RESOURCE_GOLD )+S2I(SubString(s,6,13))/4)
elseif SubString(s,0,7)=="-lumber" then
call SetPlayerState(p,PLAYER_STATE_RESOURCE_LUMBER,GetPlayerState(p,PLAYER_STATE_RESOURCE_LUMBER )+S2I(SubString(s,8,15))/4)
and it should be fine. ;)

_________________
Get Your Map Making Pack Here! :wink:
Good flash games website! Come join me and have fun! :O
Image


Top
 Profile  
 
 Post subject: Re: Activation code
PostPosted: October 26th, 2007, 11:10 pm 
Offline
Member

Joined: May 22nd, 2007, 1:12 am
Posts: 55
Thank you very much weirdone. I also love your cheat pack (although it sometimes makes the map I apply it to cause WC to crash, and other time it just doesn't work at all).

Georgemots wrote:
somehow off-topic
Shouldn't this be

from
Code:
if SubString(GetEventPlayerChatString(),0,8)=="-penguin" then


to
this
Quote:
if SubString(GetEventPlayerChatString(),0,9)=="-penguin" then


"-penguin" is 8 characters, so it should be 0,8.


Top
 Profile  
 
 Post subject: Re: Activation code
PostPosted: October 27th, 2007, 12:16 am 
Offline
Senior Member
User avatar

Joined: February 20th, 2007, 8:40 pm
Posts: 132
Location: Canada!!!
Title: Random Noob
Penguin wrote:
"-penguin" is 8 characters, so it should be 0,8.

Actually, it should be 0,7
- 0
p 1
e 2
n 3
g 4
u 5
i 6
n 7

Jass counts the first character as 0, not 1.

_________________
If you knew a woman who was pregnant, who had 8 kids already,
three who were deaf, two who were blind, one mentally retarded, and she had syphilis; would you recommend that she have an abortion?

Answer:
Spoiler:
If you said yes, you just killed Beethoven...


Top
 Profile  
 
 Post subject: Re: Activation code
PostPosted: October 27th, 2007, 12:33 am 
Offline
Legendary Genius
User avatar

Joined: August 8th, 2007, 8:10 am
Posts: 1318
Location: St. George Utah
Title: Legendary Genius²
I'm not sure how to explain this but I think it works like this...
It starts at 1 and ends at whatever number specifed because 0 can't really be counted because that's not possible to put a string there because when you say "whatever" w=1 h=2 a=3 etc...

So 0 is simply like a precheck or whatever you want to call it...
Example (s,1,2) would just check to see where the 2nd char of what you say is...

_________________
Computer Specs:
Motherboard: GA-990FXA-UD3
CPU: FX-8350 @ 4.0GHz
PSU: Corsair CX500
RAM: G.Skill Ripjaws X 8GB @ 1866
GPU: Radeon HD 4870 1GB
HDD: OCZ Vertex series 30GB SSD
Case: Antec 900
Monitor: Toshiba 32"
OS: Windows 7 Ultimate


Top
 Profile  
 
 Post subject: Re: Activation code
PostPosted: October 27th, 2007, 4:15 pm 
Offline
Forum Staff
User avatar

Joined: June 3rd, 2007, 8:03 pm
Posts: 1008
Trb if you stopped at 7 then one would only have to enter -pengui, it works liek this substring(source,start(where you wish to start at),end(ending does not get this char)) so lets say i have k="1234" Substring(k,0,3) This would look at the start 0, which is 1 then get 1 which is 2 also 2 which is 3 and then would see that its at 3(the end) so would stop. So in the end it would return "123"

@penguin thx, ya I know of the lil crash bug just haven't really tried to find it yet. :P And the 2nd is the vex error. :S

_________________
Get Your Map Making Pack Here! :wink:
Good flash games website! Come join me and have fun! :O
Image


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 15 posts ]  Go to page Previous  1, 2

All times are UTC


Who is online

Users browsing this forum: No registered users and 15 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group

phpBB SEO


Privacy Policy Statement
Impressum (German)