Title: 2 Questions about 2 row of code . 0.01 BTC as reward to the first who explain. Post by: Terminator3018 on February 14, 2014, 11:40:10 PM [0.01 BTC as reward to the first who answer me with the explanation]
Hi, What are the parts marked in red used for? txNew.vin[0].scriptSig = CScript() << 0x0197d877 << CBigNum(4) << vector<unsigned char>((const unsigned char*)pszTimestamp, (const unsigned char*)pszTimestamp + strlen(pszTimestamp)); unsigned char pchMessageStart[4] = { 0x01, 0x97, 0xd8, 0x77 }; [Extra 0.005 BTC as reward if you answer to this too] I'm also not sure what time should be used in this row : block.nTime = 1390586275; I know that I should use the "epochtime" but when should I copy it? I mean from when?As soon as I start to launch my coin? Thank you in advance Best regards Edit : Rewards increased. Title: Re: 2 Questions about 2 row of code . 0.005 BTC as reward to the first who explain. Post by: roslinpl on February 14, 2014, 11:46:08 PM Small bounty...
Those are ... refs to memory sectors? :-) Title: Re: 2 Questions about 2 row of code . 0.005 BTC as reward to the first who explain. Post by: Terminator3018 on February 15, 2014, 09:16:15 AM I don't think so. Because for different source codes of different currencies there are different "numbers".
Title: Re: 2 Questions about 2 row of code . 0.01 BTC as reward to the first who explain. Post by: Terminator3018 on February 15, 2014, 09:23:13 AM Small bounty... Those are ... refs to memory sectors? :-) I just raised up the buonties ;) Title: Re: 2 Questions about 2 row of code . 0.01 BTC as reward to the first who explain. Post by: Ix on February 15, 2014, 09:23:41 AM I don't know about the first one, but the second one is the magic bytes (https://en.wikipedia.org/wiki/Magic_number_(programming)#Magic_numbers_in_protocols) of the protocol for identification.
Title: Re: 2 Questions about 2 row of code . 0.01 BTC as reward to the first who explain. Post by: Terminator3018 on February 15, 2014, 09:29:00 AM I don't know about the first one, but the second one is the magic bytes (https://en.wikipedia.org/wiki/Magic_number_(programming)#Magic_numbers_in_protocols) of the protocol for identification. Yeah , I know that but what should I write instead of them?What bytes should I use? Title: Re: 2 Questions about 2 row of code . 0.01 BTC as reward to the first who explain. Post by: tgendev on February 15, 2014, 09:33:34 AM A salt value is a random value.
Title: Re: 2 Questions about 2 row of code . 0.01 BTC as reward to the first who explain. Post by: Terminator3018 on February 15, 2014, 09:37:05 AM With "salt value" you mean the magic numbers?
Title: Re: 2 Questions about 2 row of code . 0.01 BTC as reward to the first who explain. Post by: djarot on February 15, 2014, 10:16:44 AM lemme try
Code: unsigned char pchMessageStart[4] = { 0x01, 0x97, 0xd8, 0x77 }; 0x01 The next opcode bytes is data to be pushed onto the stack 0x97 a b out Returns the remainder after dividing a by b. disabled. 0xd8 ?? 0x77 Removes the second-to-top stack item. Title: Re: 2 Questions about 2 row of code . 0.01 BTC as reward to the first who explain. Post by: Terminator3018 on February 15, 2014, 12:56:45 PM So , let's say I want to edit this crypto-currency and make my own. Should I put random numbers instead of these? Or should I leave this unchanged?
Title: Re: 2 Questions about 2 row of code . 0.01 BTC as reward to the first who explain. Post by: rat4 on February 15, 2014, 03:21:20 PM unsigned char pchMessageStart[4] = { 0x01, 0x97, 0xd8, 0x77 }; It's magic identification number. You can leave this as is or choose new random one. Does not really matter. I'm also not sure what time should be used in this row : block.nTime = 1390586275; I know that I should use the "epochtime" but when should I copy it? I mean from when?As soon as I start to launch my coin? It's timestamp of genesis (first) block. Put there timestamp of launch. (timestamp = epochtime) Title: Re: 2 Questions about 2 row of code . 0.01 BTC as reward to the first who explain. Post by: Terminator3018 on February 15, 2014, 03:41:37 PM Please provide me your BTC address so I can send you part of the reward.
What about the first row?Do you have any clue of what is it used about or what should I change it with? With the "timestamp of launch" you mean when I will update my thread containing the currency source code on github? Thank you. Title: Re: 2 Questions about 2 row of code . 0.01 BTC as reward to the first who explain. Post by: rat4 on February 15, 2014, 04:34:55 PM Quote What about the first row?Do you have any clue of what is it used about or what should I change it with? "txNew.vin[0].scriptSig = " can be anything; it isn't used. See https://en.bitcoin.it/wiki/Transactions#Generation (https://en.bitcoin.it/wiki/Transactions#Generation) Quote With the "timestamp of launch" you mean when I will update my thread containing the currency source code on github? I mean start of mining. My BTC address: 14T4i9rQmG7zufSgxLbcKhwwRG5VykyoYy Thanks Title: Re: 2 Questions about 2 row of code . 0.01 BTC as reward to the first who explain. Post by: Terminator3018 on February 15, 2014, 07:15:39 PM Bitcoins sent , please check.
Add me on skype if you want , I'll probably need more tips in the future. Skype id : terminaattore Thank you again. Title: Re: 2 Questions about 2 row of code . 0.01 BTC as reward to the first who explain. Post by: rat4 on February 15, 2014, 08:04:37 PM BTC are received. I don't use skype, feel free to send PM.
Title: Re: 2 Questions about 2 row of code . 0.01 BTC as reward to the first who explain. Post by: roslinpl on February 16, 2014, 12:26:07 AM BTC are received. I don't use skype, feel free to send PM. task done :) nice! Congrats to a winner! |