[Help] Wrong IDs?

11/03/2011 13:40 JobvdH#1
Hello all,

I have a question.
Thanks to 12tails and pro4never I've got it done to make transformations possible.
It now shows me an restore button and a countdown :).

But now 2 questions:
1: Whats the packet for restore? (Now it won't restore and button dissapear).
2: Everytime I want to transform I`ll be invisible or a whole other mesh..

My code is in the spoiler:

Does anyone have a clue??

Thanks,
JobvdH!
11/03/2011 14:04 Korvacs#2
Its like you want us to write your source for you, maybe we should start charging =x
11/03/2011 14:11 pro4never#3
you need to learn to COMBINE SEPARATE VALUES when you send the mesh value...

You don't keep boosting the value you hold them as separate and only combine when you need the combined value.


Korv is right.. I'll code the whole disguise system for 50 bux if you want :D
11/03/2011 14:19 JobvdH#4
So...
Means..
I got to combine, mesh * 10000000 + avatar * 10000 + normal mesh?

EDIT: I already found the General Data subtype for restore button!!
11/03/2011 14:39 pro4never#5
Quote:
Originally Posted by JobvdH View Post
So...
Means..
I got to combine, mesh * 10000000 + avatar * 10000 + normal mesh?

EDIT: I already found the General Data subtype for restore button!!
Exactly. Personally I use get/set accessors for each mesh part and a simple get accessor for the final mesh which combines them. I NEVER alter them or do the actual multiplication inside the variable. It's much easier to know what transformation id 223 or w/e is compared to 2230000000 off the top of your head.
11/03/2011 14:54 JobvdH#6
Alright..
Now I got this:

Code:
                            OldMesh = Model;
                            Transformed = true;
                            TransformStamp = DateTime.Now;
                            TransformModel = (223 * 10000000L);
                            Model = ulong.Parse(TransformModel.ToString() + Avatar.ToString() + Model.ToString());
                            MyClient.SendPacket(Program.MyPackets.Vital(UID, 12, ulong.Parse(Avatar.ToString() + Model.ToString())));
                            MyClient.SendPacket(Program.MyPackets.Vital(UID, 26, GetStat()));
                            World.UpdateSpawn(MyClient.MyChar);
But uhh...
When I do this:
Code:
                            OldMesh = Model;
                            Transformed = true;
                            TransformStamp = DateTime.Now;
                            TransformModel = (223 * 10000000L);
                            Model = ulong.Parse(TransformModel.ToString() + (Avatar * 10000).ToString() + Model.ToString());
                            MyClient.SendPacket(Program.MyPackets.Vital(UID, 12, ulong.Parse(Avatar.ToString() + Model.ToString())));
                            MyClient.SendPacket(Program.MyPackets.Vital(UID, 26, GetStat()));
                            World.UpdateSpawn(MyClient.MyChar);
It gives me an error that it is to big for an Int64 >_>

Now it transforms but in a different mesh..
11/03/2011 15:18 pro4never#7
mesh is an uint... not a ulong...

You're doing tostring! That is wrong it's pasting the numbers infront of eachother


1000000 + 10000 becomes


100000010000

This is not correct... as we said in the original thread just look at how other sources do it.. it's really simple.