←  Pytania

AMXX.pl: Support AMX Mod X i SourceMod

»

Prozba o 2 itemki

Locked

  • +
  • -
SzukamProDM's Photo SzukamProDM 17.12.2009

Witam, mam prozbe czy moglby ktos mi napisac kod na itemek:

- Crossbow hunter
Item dodawalby kusze

- Flashlight sorcerer
Item dodawalby latarke maga


@ Z gory dziekuje, beda pochwalki:)
Quote

honey's Photo honey 17.12.2009

2. Znajdź:
if(flashlight[id] && flashbattery[id] && (get_cvar_num("flashlight_custom")) && (player_class[id] == Mag)) {

i zamień na:
if(flashlight[id] && flashbattery[id] && (get_cvar_num("flashlight_custom")) && ((player_class[id] == Mag) || (player_item_id[id] == numer itemu)))
Quote

  • +
  • -
SzukamProDM's Photo SzukamProDM 17.12.2009

czyli przy latarce maga dodaje tylko palyer_item_id dodaje do item do case i tyle..?
Quote

honey's Photo honey 17.12.2009

czyli przy latarce maga dodaje tylko palyer_item_id dodaje do item do case i tyle..?


Tak jak napisałem zrób.
Quote

  • +
  • -
SzukamProDM's Photo SzukamProDM 17.12.2009

/groups/amxmodx/tmp3/textzF4mjQ.sma(1525) : error 017: undefined symbol "numer"
/groups/amxmodx/tmp3/textzF4mjQ.sma(1525) : error 029: invalid expression, assumed zero
/groups/amxmodx/tmp3/textzF4mjQ.sma(1525 -- 1526) : warning 215: expression has no effect
/groups/amxmodx/tmp3/textzF4mjQ.sma(1526) : warning 217: loose indentation
/groups/amxmodx/tmp3/textzF4mjQ.sma(1560) : warning 204: symbol is assigned a value that is never used: "button2"
/groups/amxmodx/tmp3/textzF4mjQ.sma(1563) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1567) : error 021: symbol already defined: "entity_get_vector"
/groups/amxmodx/tmp3/textzF4mjQ.sma(1569) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1573) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1577) : error 029: invalid expression, assumed zero
/groups/amxmodx/tmp3/textzF4mjQ.sma(1577 -- 1579) : warning 215: expression has no effect
/groups/amxmodx/tmp3/textzF4mjQ.sma(1579) : warning 209: function "command_bow" should return a value
/groups/amxmodx/tmp3/textzF4mjQ.sma(1579) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1582) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1583) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1585) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1588) : error 021: symbol already defined: "pev"
/groups/amxmodx/tmp3/textzF4mjQ.sma(1590) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1591) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1595) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1596) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1597) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1598) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1599) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1604) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1606) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1614) : error 029: invalid expression, assumed zero
/groups/amxmodx/tmp3/textzF4mjQ.sma(1614 -- 1615) : warning 215: expression has no effect
/groups/amxmodx/tmp3/textzF4mjQ.sma(1615) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1619) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1620) : error 010: invalid function or declaration
/groups/amxmodx/tmp3/textzF4mjQ.sma(1623) : error 010: invalid function or declaration

Compilation aborted.
26 Error


przy komplikaci;x
Quote

honey's Photo honey 17.12.2009

Pokaż sma, coś źle zrobiłeś ;>
Quote

  • +
  • -
SzukamProDM's Photo SzukamProDM 17.12.2009

Lap, tam pousuwalem itemki jbc.. wiec nie patrz na (1,X) ;P

Attached Files

Quote

honey's Photo honey 17.12.2009

Jak ma działać jak nie dałeś numeru itemu ? :>

Attached Files

Quote

  • +
  • -
Miczu's Photo Miczu 17.12.2009

czyli przy latarce maga dodaje tylko palyer_item_id dodaje do item do case i tyle..?


Tak jak napisałem zrób.


Jak tak mu mowisz, to co sie dziwisz, ze zrobil to co mu kazales ;>
Quote

  • +
  • -
SzukamProDM's Photo SzukamProDM 17.12.2009

moglbys na pw dac gg...?;x
Quote

  • +
  • -
Vertricus's Photo Vertricus 17.12.2009

Z tego co pamiętam do kuszy chyba jeszcze coś trzeba mianowicie ustawić model to raz i command_arrow to dwa O:)
Quote

  • +
  • -
SzukamProDM's Photo SzukamProDM 17.12.2009

Vertucus przy case X dac tak jak w latarce tylko dodac command_arrow i model ustawic..?;x
Quote

honey's Photo honey 17.12.2009

Jak tak mu mowisz, to co sie dziwisz, ze zrobil to co mu kazales ;>


Miczu, ale to chyba logiczne, że w nazwę numer itemu trzeba wstawić numerek xD

Co do kuszy, nie byłbym tego taki pewien Vert ;>
Quote

  • +
  • -
Miczu's Photo Miczu 17.12.2009

honey, on sie pytal czy dodac do case, a ty mu zaprzeczyles mowiac by zrobil tak jak mu napisales... logika tu juz nie dziala, uznal ze wiesz co mowisz ;>
Quote

honey's Photo honey 17.12.2009

Miczu, oj czepiasz się xD
Quote

  • +
  • -
SzukamProDM's Photo SzukamProDM 17.12.2009

:) Ok latarka juz...;x A teraz wie moze ktorys z panow jak kusze "ogarnac"?;P
Quote

Radeon's Photo Radeon 17.12.2009

Latarka naświetla swoich w takim rozwiązaniu - jakieś propozycje?
Quote

  • +
  • -
Miczu's Photo Miczu 17.12.2009

jendrek9, a moze celowales w kameleona? ;>
Quote

  • +
  • -
G[o]Q's Photo G[o]Q 17.12.2009

a jesli nie celowales w kameleona to pewnie trzeba warunek dodac

if (cs_get_user_team[attacer] != cs_get_user_team[ninja] )

to gdzies na poczatku funkcji naswietlania
Quote

  • +
  • -
Vertricus's Photo Vertricus 18.12.2009

new index1, bodypart1
		get_user_aiming(id,index1,bodypart1) 
		if (is_user_alive(index1) && (get_user_team(id)!=get_user_team(index1)) && (index1!=0))
		{
			if ((index1!=54) && (is_user_connected(index1))) set_user_rendering(index1,kRenderFxGlowShell,flashlight_r,flashlight_g,flashlight_b,kRenderNormal,4)	
			remove_task(TASK_FLASH_LIGHT+index1);
			set_task(7.5, "un_rander",TASK_FLASH_LIGHT+index1)
			//set_task(15.0,"un_rander",TASK_NAME,index1)
			}
Sprawdź jak to wygląda. ;)
Quote
Locked