Page 57 of 60 FirstFirst ... 7 47 55 56 57 58 59 ... LastLast
Results 561 to 570 of 599

Thread: SAPP

  1. #561
    suum cuique sehe's Avatar
    Join Date
    Aug 2011
    Location
    Hungary
    Posts
    217

    Re: SAPP

    Yes, and have 0 players in your server.

    Anyways, 7.3 is out with these var commands and other stuff, so you can try and tell me if you were able to make your mod with this.
    Also, I made this assists-as-hp thing and works fine:

    init.txt:
    var_add health 2
    (As a global variable, since it's only used as temporary, no need one for every player)

    events.txt:
    event_alive 'var_set health $hp;var_set health *100;var_conv health;cevent hpassists $n;var_conv health'
    event_custom $ename:hpassists 'assists $n $health'
    event_die 'assists $n 0'

  2. #562

    Re: SAPP

    Here's what I have of a hunt mode so far

    I am having a problem with it though, the player variable 'playerhunted' is never 1, even when i explicitly set it to 1 and remove any case where it's set to 0.\

    Code:
    ;;Game Logic
    event_start $mode:Hunt 'var_add Hunt 1;var_set Hunt 1;cevent InitHunt'
    event_custom $ename:InitHunt $mode:Hunt 'cheat_jetpack 1;timelimit $pn*3;sv_name "  XVS.Arcadium(() => new Hunt(DeathIsland))"'
    event_custom $ename:InitHunt $mode:Hunt 'var_add Round 1;var_add RoundTime 1;var_set RoundTime 10;var_add Hunter 1;var_add chkReported 1;var_add chkHunted 1'
    event_custom $ename:InitHunt $mode:Hunt 'var_add Debug 1;var_set Debug 1;var_add playerhunted 4;var_add plyReported 4'
    event_custom $ename:InitHunt $mode:Hunt 'cevent EndRound;cevent clk;cevent InitPlayer'
    event_custom $ename:InitPlayer $n=0 $pn>0 'var_add iply 1;var_set iply 1;cevent InitPlayer $iply;w8 1;var_del iply'
    event_custom $ename:InitPlayer $n>0 $pn>=$iply 'var_set iply +1;st $n blue;wait 100;cevent InitPlayer $iply'
    
    
    event_end $mode:Hunt 'cevent EndHunt'
    event_custom $ename:EndHunt $mode:Hunt 'cheat_jetpack 0;sv_name "  XVS.Arcadium( > Game Over < )"'
    event_custom $ename:EndHunt $mode:Hunt 'var_del Round;var_del RoundTime;var_del Hunter;var_del chkReported;var_del chkHunted'
    event_custom $ename:EndHunt $mode:Hunt 'var_del Debug;var_del playerhunted;var_del plyReported'
    event_join $mode:Hunt 'var_set playerhunted 0;st $n blue;timelimit +2'
    event_leave $mode:Hunt 'timelimit -1'
    event_leave $mode:Hunt $playerhunted=1 'timelimit -1;var_set playerhunted 0'
    event_custom $ename:clk $Round<3 'w8 1;cevent clk'
    event_custom $ename:clk $RoundTime>0 'var_set RoundTime -1'
    
    
    ;; Debugger
    event_custom $ename:HuntDebug $mode:Hunt $Debug=0 'sv_say "Debug mode enabled";var_add debugRound 1;var_add debugHunter 1;wait 500;var_set Debug 1;var_add dply 1'
    event_custom $ename:HuntDebug $mode:Hunt $Debug=1 'sv_say "Debug mode disabled";var_set Debug 0;var_del debugRound;var_del debugHunter'
    
    
    event_custom $ename:DebugDump $n=0 $mode:Hunt 'sv_say "Round: $Round, Hunter: $Hunter, Round Time: $RoundTime"'
    event_custom $ename:DebugDump $n!=0 $mode:Hunt 'sv_say "$name: Hunted: $playerhunted Health: $hp Shield: $sh"'
    
    
    event_custom $ename:clk 'cevent DebugDump'
    event_custom $ename:InitPlayer $n=0 'sv_say "Initializing Players..."'
    event_custom $ename:InitPlayer $n>0 'sv_say "Setting $name to hunt";cevent DebugDump $n'
    
    
    event_custom $Debug=1 $ename:StartRound $mode:Hunt 'sv_say "The Hunting Round begins.";cevent DebugDump;cevent DebugDump $Hunter'
    event_alive $Debug=1 $mode:Hunt $Round=0 $n=$Hunter $RoundTime<=0 'sv_say "Hunter has survived and will get another turn"'
    event_custom $Debug=1 $ename:EndRound $mode:Hunt 'sv_say "The Post Round begins";cevent DebugDump'
    event_spawn $Debug=1 $mode:Hunt $Round=1 $playerhunted=0 $Hunter=0 'sv_say "$name qualifies to be the hunter";cevent DebugDump $n'
    event_alive $Debug=1 $mode:Hunt $Round=1 $playerhunted=0 $Hunter=0 'sv_say "$name qualifies to be the hunter";cevent DebugDump $n'
    event_alive $Debug=1 $Round=1 $RoundTime<=0 $mode:Hunt 'sv_say "Post Round is over, continue to selection."'
    event_alive $Debug=1 $mode:Hunt $Round=2 $Hunter!=0 'sv_say "The hunter has already been chosen, skip selection."'
    event_alive $Debug=1 $mode:Hunt $Round=2 $plyReported=0 'sv_say "$name reporting... $chkReported+1"'
    event_alive $Debug=1 $mode:Hunt $Round=2 $playerhunted=1 'sv_say "$name has hunted before -- will not hunt again.";cevent DebugDump;cevent DebugDump $n'
    event_alive $Debug=1 $mode:Hunt $Round=2 $chkHunted=$pn 'sv_say "All players reporting and hunt limit is reached, the game will not continue.";cevent DebugDump'
    event_alive $Debug=1 $mode:Hunt $Round=2 $chkReported=$pn 'sv_say "All players reporting and hunt limit not reached, the game will continue.";cevent DebugDump'
    
    
    ;;;;;;;;;;;;;;;;;;
    
    
    ;; Hunting Round
    event_custom $ename:StartRound $mode:Hunt 'var_set Round 0;var_set RoundTime 120;cheat_deathless_player 0;slayer_score_team red $RoundTime;t $Hunter hunterspawn;w8 1;spawn vehi vehicles\banshee\banshee_mp $Hunter;venter $Hunter'
    event_alive $mode:Hunt $Round=0 $n=$Hunter $RoundTime<=0 'say * "$name lives to hunt again!";var_set playerhunted 0;cevent EndRound'
    event_alive $mode:Hunt $Round=0 $plyReported=1 'var_set plyReported 0'
    
    
    event_kill $mode:Hunt $Round=0 $n=$Hunter $combo=1 'wait 200;say * "+3 seconds";var_set RoundTime +3'
    event_kill $mode:Hunt $Round=0 $n=$Hunter $combo=2 'wait 200;say * "Double Kill! +5 seconds";var_set RoundTime +5'
    event_kill $mode:Hunt $Round=0 $n=$Hunter $combo=3 'wait 200;say * "Triple Kill! +10 seconds";var_set RoundTime +10'
    event_kill $mode:Hunt $Round=0 $n=$Hunter $combo>=4 'wait 200;say * "Multi Kill! +15 seconds";var_set RoundTime +15'
    
    
    event_die $mode:Hunt $Round=0 $n=$Hunter 'say * "The hunt is over!";cevent EndRound'
    
    
    event_teamswitch $n=$Hunter $team:blue 'wait 200;st $n red'
    event_die $n=$Hunter $team:blue 'wait 200;st $n red'
    event_teamswitch $n!=$Hunter $team:red 'wait 200;st $n blue'
    event_die $n!=$Hunter $team:red 'wait 200;st $n blue'
    
    
    ;; Post Round
    event_custom $ename:EndRound $mode:Hunt 'var_set Hunter 0;var_set Round 1;wait 200;say * "Next round begins in 10 seconds.";cheat_deathless_player 1;mag * 3200 5;battery * 3200 5'
    event_alive $mode:Hunt $Round=1 's * $RoundTime/10'
    event_spawn $mode:Hunt $Round=1 $playerhunted=0 $Hunter=0 'var_set Hunter $n;var_set playerhunted 1;wait 200;st $n red;w8 2;say * "$name is the next Hunter"'
    event_alive $mode:Hunt $Round=1 $playerhunted=0 $Hunter=0 'var_set Hunter $n;var_set playerhunted 1;kill $n;wait 500;st $n red;w8 1;say * "$name is the next Hunter"'
    event_alive $Round=1 $RoundTime<=0 $mode:Hunt 'kill *;wait 100;vdel *;wait 200;st * blue;var_set Round 2;var_set PostRound 10'
    
    
    ;; Selection Round
    event_alive $mode:Hunt $Round=2 $Hunter!=0 'cevent StartRound'
    event_alive $mode:Hunt $Round=2 $plyReported=0 $playerhunted=1 'var_set chkHunted +1'
    event_alive $mode:Hunt $Round=2 $plyReported=0 'var_set chkReported +1;var_set plyReported 1'
    event_alive $mode:Hunt $Round=2 $chkHunted=$pn 'god *;s * 0;say * "Everyone has hunted... The game is over!";var_set Round 3;sv_map_next'
    event_alive $mode:Hunt $Round=2 $chkReported=$pn 'var_set Round 0'
    
    
    ;; Kill messages
    event_kill $mode:Hunt $Round=0 $n!=$Hunter 'var_add Randomchat;var_set Randomchat $rand'
    event_kill $mode:Hunt $Round=0 $n!=$Hunter $Randomchat=1 'say * "$name killed the hunter!";var_set Randomchat 0'
    event_kill $mode:Hunt $Round=0 $n!=$Hunter $Randomchat=2 'say * "$name ended the hunter!";var_set Randomchat 0'
    event_kill $mode:Hunt $Round=0 $n!=$Hunter $Randomchat=3 'say * "$name stopped the hunter!";var_set Randomchat 0'
    event_kill $mode:Hunt $Round=0 $n!=$Hunter $Randomchat=4 'say * "$name cancelled the hunter!";var_set Randomchat 0'
    event_kill $mode:Hunt $Round=0 $n!=$Hunter $Randomchat=5 'say * "$name terminated the hunter!";var_set Randomchat 0'
    event_kill $mode:Hunt $Round=0 $n!=$Hunter $Randomchat=6 'say * "$name hunted the hunter!";var_set Randomchat 0'
    event_kill $mode:Hunt $Round=0 $n!=$Hunter $Randomchat=7 'say * "$name wrecked the hunter!";var_set Randomchat 0'
    event_kill $mode:Hunt $Round=0 $n!=$Hunter $Randomchat=8 'say * "$name denied the hunter!";var_set Randomchat 0'
    
    
    event_kill $mode:Hunt $Round=0 $n!=$Hunter $Randomchat=9 'say * "$name killed the hunter!";var_set Randomchat 0'
    event_kill $mode:Hunt $Round=0 $n!=$Hunter $Randomchat=10 'say * "$name ended the hunter!";var_set Randomchat 0'
    event_kill $mode:Hunt $Round=0 $n!=$Hunter $Randomchat=11 'say * "$name stopped the hunter!";var_set Randomchat 0'
    event_kill $mode:Hunt $Round=0 $n!=$Hunter $Randomchat=12 'say * "$name cancelled the hunter!";var_set Randomchat 0'
    event_kill $mode:Hunt $Round=0 $n!=$Hunter $Randomchat=13 'say * "$name terminated the hunter!";var_set Randomchat 0'
    event_kill $mode:Hunt $Round=0 $n!=$Hunter $Randomchat=14 'say * "$name hunted the hunter!";var_set Randomchat 0'
    event_kill $mode:Hunt $Round=0 $n!=$Hunter $Randomchat=15 'say * "$name wrecked the hunter!";var_set Randomchat 0'
    event_kill $mode:Hunt $Round=0 $n!=$Hunter $Randomchat=16 'say * "$name denied the hunter!";var_set Randomchat 0'
    event_kill $mode:Hunt $Round=0 $n!=$Hunter 'var_del Randomchat'
    Also, can you add an event_load event? event_start doesn't fire when I run reload, which is quite often when trying to debug this behemoth.
    Last edited by SonicXP; May 11th, 2014 at 01:04 PM.

  3. #563
    suum cuique sehe's Avatar
    Join Date
    Aug 2011
    Location
    Hungary
    Posts
    217

    Re: SAPP

    Use Sapp's init.txt for that?

    And it's because you have to specify which player's variable you want to set, like 'var_set playerhunted 1 $n'
    Perhaps I forgot to mention it, hehe.

  4. #564

    Re: SAPP

    Quote Originally Posted by sehe View Post
    Use Sapp's init.txt for that?

    And it's because you have to specify which player's variable you want to set, like 'var_set playerhunted 1 $n'
    Perhaps I forgot to mention it, hehe.
    I forgot sapp had its own init :v

    Also, I've encountered some strange bug pertaining to maths.
    Using what you wrote, when the player is near 0 health (under 0.1 or 0.01), it becomes some absurd number like 200. That is, the converted variable, not the actual $hp.

    Also also, will it be possible to perform arithmetic between two variables and not just a variable and a number? I've found myself trying to calculate the difference in health when a player's health changes, but the result is always 0. I could use a counter variable, but I'm not sure I want to write an event loop every time somebody takes damage.

  5. #565
    suum cuique sehe's Avatar
    Join Date
    Aug 2011
    Location
    Hungary
    Posts
    217

    Re: SAPP

    That might be just the bug in cevent, try with the new version 7.3.1...

    I don't exactly understand what you mean, you can do like var_set oldhp -$hp $n
    But if you want to write such complex scripts just use Phasor or wait till I add Lua (if ever)

    Also, do you have Skype/Xfire where we can talk easier abt these modding stuff?

  6. #566

    Re: SAPP

    Hey sehe, the desync things is still happening for me with custom_sleep 8 (which is apparently Halo's default according to xhalo.tk). Any other suggested values?

  7. #567
    Senior Member sanni's Avatar
    Join Date
    May 2010
    Location
    SPARTAN
    Posts
    117

    Re: SAPP

    You need to set it to custom_sleep 0

  8. #568

    Re: SAPP

    Oh OK, I assumed that I wanted what default Halo used instead of what SAPP used since I've never ever had this problem with a default Halo CE dedicated server. Only happens with SAPP.

    I'll try 0 this weekend and see what happens.

  9. #569
    suum cuique sehe's Avatar
    Join Date
    Aug 2011
    Location
    Hungary
    Posts
    217

    Re: SAPP

    Sapp 8.0 with basic Lua is out: http://xhalo.tk/changelog/

  10. #570
    Junior Member
    Join Date
    May 2014
    Posts
    3

    Re: SAPP

    thank you very much, but why have not my servers with the 8.0 update?

Thread Information

Users Browsing this Thread

There are currently 4 users browsing this thread. (0 members and 4 guests)

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •