[C++] Functions for adding an effect on a costume

06/22/2016 14:18 VegaS ♆#1
#old
06/22/2016 16:49 xCPx#2
Nice Idea, but why do you allways make things via thousand ifs?

why not simply with a foreach of a dictionary or so?
06/23/2016 04:44 kstmr#3
first of all nice release and thx. about the coding as xCPx said c++ has loops,(arrays/maps),iteration think about using them. (you don't have to use c++11)
better idea for ppl who plan to recode it and make it more simple to use :
metin2 has cpython module that are easy to manage. go get them.
06/23/2016 11:14 Remix v138#4
to be honest thats horrible

do you even know how enums work?

Code:
enum ECostumeEffectMsm
{
	VALUE_MSM_1 = 40032, // = vnum [ (M) -> 41003, (F) -> 41004]
	VALUE_MSM_2, // = vnum [ (M) -> 41005, (F) -> 41006]
	VALUE_MSM_3, // = vnum [ (M) -> 41007, (F) -> 41008]
	VALUE_MSM_4, // = vnum [ (M) -> 41009, (F) -> 41010]
	VALUE_MSM_5, // = vnum [ (M) -> 41011, (F) -> 41012]
	VALUE_MSM_6, // = vnum [ (M) -> 41013, (F) -> 41014]
	VALUE_MSM_7, // = vnum [ (M) -> 41015, (F) -> 41016]
	VALUE_MSM_8, // = vnum [ (M) -> 41017, (F) -> 41018]
	VALUE_MSM_9, // = vnum [ (M) -> 41019, (F) -> 41020]
	VALUE_MSM_10 // = vnum [ (M) -> 41021, (F) -> 41022]
};
you dont need to specify a value for everything
it automatically adds 1if the first value was specified (if not, it starts with 0)

also, theres a lack of mathematical knowledge

Code:
if(szMsm >= VALUE_MSM_1 && szMsm <= VALUE_MSM_10)
works as well