public Rock_Slide(id, skill, prop) { new Float:f_aimvec[3], Ent new rockammount = 1+(SkillLevel(id, skill) / ROCK_SLIDE_LEVEL) get_user_origin(id, origin[id]); get_user_origin(id, aim[id], 3); if(-50>aim[id][0]-origin[id][0]>50) //only change it if they are at least that far away aim[id][0] += ( ( aim[id][0] - origin[id][0] > 0 ) ? -50 : 50 ); if(-50>aim[id][1]-origin[id][1]>50) //only change it if they are at least that far away aim[id][1] += ( ( aim[id][1] - origin[id][1] > 0 ) ? -50 : 50 ); if(-50>aim[id][2]-origin[id][2]>50) //only change it if they are at least that far away aim[id][2] += ( ( aim[id][2] - origin[id][2] > 0 ) ? -50 : 50 ); else aim[id][2] += 40; for(new i=0; i<rockammount; i++){ Ent = fm_create_entity("info_target") if (!Ent) continue set_pev(Ent, pev_classname, "pokemod_ent") set_pev(Ent, pev_owner, id) IVecFVec(aim[id], f_aimvec) f_aimvec[0] += random_float(-100.0,100.0) f_aimvec[1] += random_float(-100.0,100.0) fm_entity_set_origin(Ent, f_aimvec) ChangeToBoulder(Ent, skill) set_pev(Ent, pev_velocity, Float:{0.0,0.0,1000.0}) set_task(0.1, "CheckBoulder", Ent) } return SKILL_USED } public CheckBoulder(ent) { if( pev_valid(ent) ){ new Float:velocity[3] pev(ent, pev_velocity, velocity) if(velocity[2]<1 || velocity[0] || velocity[1]){ poke_sound(ent,CHAN_VOICE, SND_TU_FIRE) set_pev(ent, pev_velocity, Float:{0.0,0.0,-50.0} ) set_pev(ent, pev_classname, "poke_rock") fm_entity_set_model(ent, MODELS[MDL_ROCK]) } else set_task(0.1, "CheckBoulder", ent) } } ChangeToBoulder(Ent, skill) { set_pev(Ent, pev_iuser2, skill) set_pev(Ent, pev_mins, Float:{-10.0, -10.0, -10.0}) set_pev(Ent, pev_maxs, Float:{10.0, 10.0, 10.0}) set_pev(Ent, pev_solid, SOLID_TRIGGER) set_pev(Ent, pev_movetype, MOVETYPE_TOSS) return SKILL_USED }
Witamy w Nieoficjalnym polskim support'cie AMX Mod X
Witamy w Nieoficjalnym polskim support'cie AMX Mod X, jak w większości społeczności internetowych musisz się zarejestrować aby móc odpowiadać lub zakładać nowe tematy, ale nie bój się to jest prosty proces w którym wymagamy minimalnych informacji.
|
Guest Message by DevFuse
symbol already defined "CheckBoulder"
Temat rozp. Danix., 01.06.2011 15:23
2 odpowiedzi w tym temacie
#1
Napisano 01.06.2011 15:23
Witam. Mam pewien problem przy kompilacji, a mianowicie. Przy kompilowaniu pokemoda wystawił problem symbol already defined "CheckBoulder", oraz symbol already defined "ChangeToBoulder". Nie mam bladego pojęcia jak naprawić ten problem. Tu zamieszczam kod pliku o który chodzi, a w załączniku zamieszczam ss z błędu. Czekam na szybką pomoc.
#2
Napisano 01.06.2011 15:29
Daj cały kod ...!
#3
Napisano 01.06.2011 15:33
public Rock_Throw(id, skill, prop) { new Float:origin[3], Float:angle[3], Float:velocity[3], Ent pev(id, pev_origin, origin) pev(id, pev_v_angle, angle) origin[2] += 20 Ent = fm_create_entity("info_target") if (!Ent) return SKILL_READY ChangeToBoulder(Ent, skill) set_pev(Ent, pev_classname, "poke_rock") fm_entity_set_model(Ent, MODELS[MDL_ROCK]) set_pev(Ent, pev_owner, id) fm_entity_set_origin(Ent, origin) set_pev(Ent, pev_angles, angle) velocity_by_aim(id, ROCK_THROW_VEC, velocity) set_pev(Ent, pev_velocity, velocity) poke_sound(id,CHAN_VOICE, SND_TU_FIRE) return SKILL_USED; } public Rock_Slide(id, skill, prop) { new Float:f_aimvec[3], Ent new rockammount = 1+(SkillLevel(id, skill) / ROCK_SLIDE_LEVEL) get_user_origin(id, origin[id]); get_user_origin(id, aim[id], 3); if(-50>aim[id][0]-origin[id][0]>50) //only change it if they are at least that far away aim[id][0] += ( ( aim[id][0] - origin[id][0] > 0 ) ? -50 : 50 ); if(-50>aim[id][1]-origin[id][1]>50) //only change it if they are at least that far away aim[id][1] += ( ( aim[id][1] - origin[id][1] > 0 ) ? -50 : 50 ); if(-50>aim[id][2]-origin[id][2]>50) //only change it if they are at least that far away aim[id][2] += ( ( aim[id][2] - origin[id][2] > 0 ) ? -50 : 50 ); else aim[id][2] += 40; for(new i=0; i<rockammount; i++){ Ent = fm_create_entity("info_target") if (!Ent) continue set_pev(Ent, pev_classname, "pokemod_ent") set_pev(Ent, pev_owner, id) IVecFVec(aim[id], f_aimvec) f_aimvec[0] += random_float(-100.0,100.0) f_aimvec[1] += random_float(-100.0,100.0) fm_entity_set_origin(Ent, f_aimvec) ChangeToBoulder(Ent, skill) set_pev(Ent, pev_velocity, Float:{0.0,0.0,1000.0}) set_task(0.1, "CheckBoulder", Ent) } return SKILL_USED } public CheckBoulder(ent) { if( pev_valid(ent) ){ new Float:velocity[3] pev(ent, pev_velocity, velocity) if(velocity[2]<1 || velocity[0] || velocity[1]){ poke_sound(ent,CHAN_VOICE, SND_TU_FIRE) set_pev(ent, pev_velocity, Float:{0.0,0.0,-50.0} ) set_pev(ent, pev_classname, "poke_rock") fm_entity_set_model(ent, MODELS[MDL_ROCK]) } else set_task(0.1, "CheckBoulder", ent) } } ChangeToBoulder(Ent, skill) { set_pev(Ent, pev_iuser2, skill) set_pev(Ent, pev_mins, Float:{-10.0, -10.0, -10.0}) set_pev(Ent, pev_maxs, Float:{10.0, 10.0, 10.0}) set_pev(Ent, pev_solid, SOLID_TRIGGER) set_pev(Ent, pev_movetype, MOVETYPE_TOSS) return SKILL_USED } public Stone_Edge(id, skill, prop) { new damage, victim = PokeSkillTarget(id, damage); if( ValidPlayer(victim) && Pokemod_Alive(victim) && MaxSkillChance(id,skill,damage) ){ screenshake(victim, 100, 3.0, 100); poke_print(id,print_center,"Uderzyles kogos przy pomocy Stone Edge"); poke_print(victim,print_center,"Zostales uderzony przy pomocy Stone Edge"); return SKILL_USED; } return SKILL_READY; } /* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE *{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1045\\ f0\\ fs16 \n\\ par } */
Dodano 01 czerwiec 2011 - 16:47:
Problem rozwiązany, temat do zamknięcia.
Użytkownicy przeglądający ten temat: 1
0 użytkowników, 1 gości, 0 anonimowych