• What do you need help with? Version 1
    5,001 replies, posted
[QUOTE=Vbits;21222272]can you not just have the values like effect_str[/QUOTE] What? Do you mean like have a column with a string of effects, then I'd parse that string to get the data I want?
you will need to predefine all column, you can just have some empty. even something like a wow server has about 20 columns for that reason [url]http://www.arcemu.info/wiki/index.php?title=Items[/url]
Ah. Thanks for the link. I'll just use SQL then. XML is too big of a pain to work with.
[QUOTE=raccoon12;21221667]OK, here is my file.h file -snip- Here is my main.cpp file: -snip- And the file I want to open has this in it: [code] ECHO -> 'HELLO' [/code] Everything compiles fine, but when i run the program, nothing shows on the console screen[/QUOTE] [code]File openECHO -> 'HELLO'[/code] Works fine here. Changed R:\\TEST.rac to C:\\TEST.rac as I have no drive with the letter R. When I passed it a nonexistent file, it output "ERROR OPENING FILE...". If your program isn't outputting either of these after entering a newline to pass the call to cin.get, check that you're compiling properly and running the correct executable. (For the record, I used GCC, but the program should work fine in any C++ compiler)
[code]on (release) { if (_root.intel<=_root.promo) { trace("lol2") _root.msgbox.gotoAndStop("Declined"); _root.msgbox._x = 257.7; _root.msgbox._y = 253.8; } else if (_root.intel<=_root.promo) { _root.msgbox._x = 257.7; _root.msgbox._y = 253.8; _root.promo += 8; _root.salary += 2; _root.msgbox.gotoAndStop("Accepted"); } }[/code]AS2, the first part works, the second part just doesn't for some fucking reason, it's really pissing me off. [B]NEVERMIND, [/B]I didn't switch the greater than sign.. that wasn't even needed.
uhh... why do you need another if there?
to keep the other one company
[QUOTE=Parakon;21233029]to keep the other one company[/QUOTE] But they're not in the same scope! How will they ever be together!?
Yes they are, the tabbing is just out of whack
K, so you have probably seen my little encryption program... [code] using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.IO; using System.Security.Cryptography; namespace Encryption_Basics { class Program { static void Main(string[] args) { byte[] keyToUse; byte[] IVToUse; string input = @"C:/input.txt"; string output = @"C:/output.txt"; FileStream inputStream = new FileStream(input, FileMode.Open, FileAccess.Read); FileStream outputStream = new FileStream(output, FileMode.OpenOrCreate, FileAccess.Write); SymmetricAlgorithm algo = new RijndaelManaged(); //Create a Key + IV string pass = "22"; ASCIIEncoding aEncoding = new ASCIIEncoding(); keyToUse = aEncoding.GetBytes(pass); IVToUse = aEncoding.GetBytes(pass); //Read input File byte[] fileData = new byte[inputStream.Length]; inputStream.Read(fileData, 0, (int)inputStream.Length); //Transform ICryptoTransform encryptor = algo.CreateEncryptor(keyToUse, IVToUse); //Create CryptoStream CryptoStream encryptStream = new CryptoStream(outputStream, encryptor, CryptoStreamMode.Write); encryptStream.Write(fileData, 0, fileData.Length); encryptStream.Close(); inputStream.Close(); outputStream.Close(); } } } [/code] I get this error when compiling. Specified initialization vector (IV) does not match the block size for this algorithm. Anyone know how to fix this? or atleast got any suggestions?
[QUOTE=jA_cOp;21227541][code]File openECHO -> 'HELLO'[/code] Works fine here. Changed R:\\TEST.rac to C:\\TEST.rac as I have no drive with the letter R. When I passed it a nonexistent file, it output "ERROR OPENING FILE...". If your program isn't outputting either of these after entering a newline to pass the call to cin.get, check that you're compiling properly and running the correct executable. (For the record, I used GCC, but the program should work fine in any C++ compiler)[/QUOTE] i don't even know how i managed to get my disk's letter to be R: edit: so i don't know what to do
I'm trying to make it so if PictureBox1 is touching Picturebox2, a messagebox shows, but I can't figure out how to do it. [cpp] if (pictureBox1.Top < TurdBox.Top) { MessageBox.Show("Your standing on Turd!!"); } [/cpp] This works if I'm on top of the box, or in any area above it.
[QUOTE=Chad Mobile;21238470]I'm trying to make it so if PictureBox1 is touching Picturebox2, a messagebox shows, but I can't figure out how to do it. [cpp] if (pictureBox1.Top < TurdBox.Top) { MessageBox.Show("Your standing on Turd!!"); } [/cpp] This works if I'm on top of the box, or in any area above it.[/QUOTE] Cmon man, surely you can figure it out. If you have the coordinates for the two picture boxes, it's just a matter of comparing them together. And if you're too dumb to figure it out yourself, then just give up programming altogether. You have to learn by yourself, mess around with stuff, and have some basic mathematics and logics skills.
Dude, calm down. How do I get the exact coordinates? I just started C#, you don't have to start yelling at my question.
The pictureboxes should have properties or methods for getting their coordinates. Look in the documentation for whatever class they are; that's the right way to find out this sort of thing.
[QUOTE=Xeon06;21240087]Cmon man, surely you can figure it out. If you have the coordinates for the two picture boxes, it's just a matter of comparing them together. And if you're too dumb to figure it out yourself, then just give up programming altogether. You have to learn by yourself, mess around with stuff, and have some basic mathematics and logics skills.[/QUOTE] [QUOTE=Chad Mobile]Give me the whole code to make it perfect or fuck off.[/QUOTE] (oh shit what happen here)
[QUOTE=Wipmuck;21241227][QUOTE=Chad Mobile]Give me the hole code to make it perfect or fuck off.[/QUOTE] (oh shit what happen here)[/QUOTE] [QUOTE=Chad Mobile]Give me the hole code to make it perfect or fuck off.[/QUOTE] [QUOTE=Chad Mobile]Give me the hole code to make it perfect[/QUOTE] [QUOTE=Chad Mobile]Give me the hole code[/QUOTE] [QUOTE=Chad Mobile]hole code[/QUOTE] [QUOTE=Chad Mobile]hole[/QUOTE] :ohdear:
[QUOTE=Chad Mobile;21241142]Dude, calm down. How do I get the exact coordinates? I just started C#, you don't have to start yelling at my question.[/QUOTE] [img]http://imgkk.com/i/as27.png[/img] fucking learn to intellisense
[QUOTE=Chad Mobile;21241142]Dude, calm down. How do I get the exact coordinates? I just started C#, you don't have to start yelling at my question.[/QUOTE] You already have Top no? What's the opposite of Top? That's right, Bottom! Let's see now... for the sides... Well maybe Right and Left, who knows? You could have found that answer a helluvalot faster by Googling or looking it up on MSDN or even juts plain old Intellisense like turb mentionned.
can you help me code out a image changer for my website. like a slideshow of some sort
[QUOTE=Zayfox;21241276]:ohdear:[/QUOTE] Fuck me, didn't see that.
[QUOTE=TheSpy;21242138]can you help me code out a image changer for my website. like a slideshow of some sort[/QUOTE] you should probably start it first
[QUOTE=Parakon;21242781]you should probably start it first[/QUOTE] i have the img boxes ready. i just want it to change position at a certain time.
[QUOTE=turb_;21235258]Yes they are, the tabbing is just out of whack[/QUOTE] The second one is in the else.
I need some help in C#. I'm trying to parse Gmod functions. I will give you an example. [cpp]"G.Color(int r, int g, int b[, int a])"[/cpp] That's a string. I've been trying to get the library, function name and arguments all separated from each other into a string array, but I have no clue how to do this. Any ideas? Ideally, it would turn into something like this... [cpp]{ "G", "Color", "int", "r", "int", "g", "int", "b", "@int", "a" }[/cpp] (the @ would be there for optional arguments)
[QUOTE=Dlaor;21251339]I need some help in C#. I'm trying to parse Gmod functions. I will give you an example. [cpp]"G.Color(int r, int g, int b[, int a])"[/cpp] That's a string. I've been trying to get the library, function name and arguments all separated from each other into a string array, but I have no clue how to do this. Any ideas? Ideally, it would turn into something like this... [cpp]{ "G", "Color", "int", "r", "int", "g", "int", "b", "@int", "a" }[/cpp] (the @ would be there for optional arguments)[/QUOTE] A combination of String.Split and String.Replace.
[QUOTE=Dlaor;21251339]I need some help in C#. I'm trying to parse Gmod functions. I will give you an example. [cpp]"G.Color(int r, int g, int b[, int a])"[/cpp] That's a string. I've been trying to get the library, function name and arguments all separated from each other into a string array, but I have no clue how to do this. Any ideas? Ideally, it would turn into something like this... [cpp]{ "G", "Color", "int", "r", "int", "g", "int", "b", "@int", "a" }[/cpp] (the @ would be there for optional arguments)[/QUOTE] If I do this, I go through it character by character, and have a number of buffers for the current string etc.
[QUOTE=TheBoff;21251995]If I do this, I go through it character by character, and have a number of buffers for the current string etc.[/QUOTE] This is correct. You need to parse it into an array of tokens, where a token is something like COMMA, TYPENAME or WHITESPACE. Then you can analyze our tokens and parse the tokens into something better.
So my school has a basic computer programming course, and AP Comp Sci. I already know C++ but the courses teach java. The basic course is a joke and I am trying to learn the required java so I can just skip it. AP Comp Sci is a bit more serious programming. I tried learning java and I am really put off by the case sensitivity and some of the lack of the nice things that C++ has. Is java worth learnign or should I just teach myself C# for cross platform crap? [editline]10:09PM[/editline] Seriously, the basic course started in September and they are just doing arrays.
C++ is case sensitive too... What nice things does C++ have that Java doesn't? I really don't know.
Sorry, you need to Log In to post a reply to this thread.